MCPcopy Create free account
hub / github.com/AppleWin/AppleWin / CmdConfigFont

Function CmdConfigFont

source/Debugger/Debugger_Win32.cpp:262–317  ·  view source on GitHub ↗

===========================================================================

Source from the content-addressed store, hash-verified

260
261//===========================================================================
262Update_t CmdConfigFont(int nArgs)
263{
264 int iArg;
265
266 if (!nArgs)
267 return CmdConfigGetFont(nArgs);
268 else
269 if (nArgs <= 2) // nArgs
270 {
271 iArg = 1;
272
273 // FONT * is undocumented, like VERSION *
274 if ((!strcmp(g_aArgs[iArg].sArg, g_aParameters[PARAM_WILDSTAR].m_sName)) ||
275 (!strcmp(g_aArgs[iArg].sArg, g_aParameters[PARAM_MEM_SEARCH_WILD].m_sName)))
276 {
277 ConsoleBufferPushFormat("Lines: %d Font Px: %d Line Px: %d"
278 , g_nDisasmDisplayLines
279 , g_aFontConfig[FONT_DISASM_DEFAULT]._nFontHeight
280 , g_aFontConfig[FONT_DISASM_DEFAULT]._nLineHeight);
281 ConsoleBufferToDisplay();
282 return UPDATE_CONSOLE_DISPLAY;
283 }
284
285 int iFound;
286 int nFound;
287
288 nFound = FindParam(g_aArgs[iArg].sArg, MATCH_EXACT, iFound, _PARAM_GENERAL_BEGIN, _PARAM_GENERAL_END);
289 if (nFound)
290 {
291 switch (iFound)
292 {
293 case PARAM_LOAD:
294 return CmdConfigFontLoad(nArgs);
295 break;
296 case PARAM_SAVE:
297 return CmdConfigFontSave(nArgs);
298 break;
299 // TODO: FONT SIZE #
300 // TODO: AA {ON|OFF}
301 default:
302 break;
303 }
304 }
305
306 nFound = FindParam(g_aArgs[iArg].sArg, MATCH_EXACT, iFound, _PARAM_FONT_BEGIN, _PARAM_FONT_END);
307 if (nFound)
308 {
309 if (iFound == PARAM_FONT_MODE)
310 return CmdConfigFontMode(nArgs);
311 }
312
313 return CmdConfigSetFont(nArgs);
314 }
315
316 return Help_Arg_1(CMD_CONFIG_FONT);
317}
318
319//===========================================================================

Callers

nothing calls this directly

Calls 9

CmdConfigGetFontFunction · 0.85
ConsoleBufferPushFormatFunction · 0.85
ConsoleBufferToDisplayFunction · 0.85
FindParamFunction · 0.85
CmdConfigFontLoadFunction · 0.85
CmdConfigFontSaveFunction · 0.85
CmdConfigFontModeFunction · 0.85
CmdConfigSetFontFunction · 0.85
Help_Arg_1Function · 0.85

Tested by

no test coverage detected