-
Notifications
You must be signed in to change notification settings - Fork 444
Programmatic controlling
snowie2000 edited this page May 31, 2023
·
1 revision
When mactype is running in tray mode (both user mode and admin mode), it can be controlled by posting predefined messages. And it can be easily achieved.
MacType will expose a top-level messenger window with the classname MacTypeMSGWnd
. Certain controlling messages can be sent to this window to manipulate the action of mactype.
Currently, the following messages are defined:
-
MacType-SIG-STOP
, stop mactype and exit -
MacType-SIG-RESTART
, reload the current profile without interruption -
MacType-SIG-ENABLE
, enable mactype -
MacType-SIG-DISABLE
, disable mactype
bool StopMacType() {
ULONG SigStop = ::RegisterWindowMessage("MacType-SIG-STOP");
HWND MsgWnd = ::FindWindow("MacTypeMSGWnd", NULL);
if (SigStop && MsgWnd) {
::PostMessage(MsgWnd, SigStop, 0, 0);
return true;
}
return false;
}
- Name
- HookChildProcesses
- HintingMode
- BoldWeight
- DirectWrite
- HintSmallFont
- MaxBitmap
- NormalWeight
- ItalicSlant
- GammaMode
- GammaValue
- Contrast
- RenderWeight
- BolderMode
- FontLoader
- FontLink
- FontSubstitutes
- MaxHeight
- LcdFilter
- AntiAliasMode
- UseMapping
- TextTuning
- TextTuningR
- TextTuningG
- TextTuningB
- LoadOnDemand
- CacheMaxFaces
- CacheMaxSizes
- CacheMaxBytes
- EnableKerning
- Shadow
- UseInclude