Make option descriptions more readable, fix bug in draw.c
This commit is contained in:
parent
d7bdf3fc19
commit
efe66bc72e
@ -86,68 +86,69 @@ void configMenu(bool oldPinStatus)
|
|||||||
#endif
|
#endif
|
||||||
};
|
};
|
||||||
|
|
||||||
const char *optionsDescription[] = { "Select the default EmuNAND.\n"
|
const char *optionsDescription[] = { "Select the default EmuNAND.\n\n"
|
||||||
"It will booted with no directional pad\n"
|
"It will booted with no directional pad\n"
|
||||||
"buttons pressed",
|
"buttons pressed.",
|
||||||
|
|
||||||
"Select the screen brightness",
|
"Select the screen brightness",
|
||||||
|
|
||||||
"Activate a PIN lock.\n"
|
"Activate a PIN lock.\n\n"
|
||||||
"The PIN will be asked each time\n"
|
"The PIN will be asked each time\n"
|
||||||
"Luma3DS boots.\n"
|
"Luma3DS boots.\n\n"
|
||||||
"4, 6 or 8 digits can be selected.\n"
|
"4, 6 or 8 digits can be selected.\n\n"
|
||||||
"The ABXY buttons and the directional\n"
|
"The ABXY buttons and the directional\n"
|
||||||
"pad buttons can be used as keys",
|
"pad buttons can be used as keys.",
|
||||||
|
|
||||||
"Select the New 3DS CPU mode.\n"
|
"Select the New 3DS CPU mode.\n\n"
|
||||||
"It will be always enabled.\n"
|
"It will be always enabled.\n\n"
|
||||||
"'Clock+L2' can cause issues with some\n"
|
"'Clock+L2' can cause issues with some\n"
|
||||||
"games",
|
"games.",
|
||||||
#ifdef DEV
|
#ifdef DEV
|
||||||
"Select the developer features.\n"
|
"Select the developer features.\n\n"
|
||||||
"'ErrDisp' displays debug information\n"
|
"\t* 'ErrDisp' displays debug info. "
|
||||||
"on the 'An error has occurred' screen.\n"
|
"on the 'An error has occurred' screen.\n"
|
||||||
"'UNITINFO' makes the console be always\n"
|
"\t* 'UNITINFO' makes the console be\n"
|
||||||
"detected as a development unit (which\n"
|
"always detected as a development unit (which "
|
||||||
"breaks online features and allows\n"
|
"breaks online features and\n"
|
||||||
"booting some developer software).\n"
|
"allows booting some developer software).\n"
|
||||||
"'Off' disables exception handlers\n"
|
"\t* 'Off' disables exception handlers\n"
|
||||||
"in FIRM",
|
"in FIRM.",
|
||||||
#endif
|
#endif
|
||||||
"If enabled SysNAND will be launched on\n"
|
"If enabled SysNAND will be launched on\n"
|
||||||
"boot. Otherwise, an EmuNAND will.\n"
|
"boot. Otherwise, an EmuNAND will.\n\n"
|
||||||
"Hold L on boot to switch NAND.\n"
|
"Hold L on boot to switch NAND.\n\n"
|
||||||
"To use a different EmuNAND from the\n"
|
"To use a different EmuNAND from the\n"
|
||||||
"default, hold a directional pad button\n"
|
"default, hold a directional pad button\n"
|
||||||
"(Up/Right/Down/Left equal EmuNANDs\n"
|
"(Up/Right/Down/Left equal EmuNANDs\n"
|
||||||
"1/2/3/4)",
|
"1/2/3/4).",
|
||||||
|
|
||||||
"If enabled, when holding R on boot\n"
|
"If enabled, when holding R on boot\n"
|
||||||
"EmuNAND will be booted with the\n"
|
"EmuNAND will be booted with the\n"
|
||||||
"SysNAND FIRM. Otherwise, SysNAND will\n"
|
"SysNAND FIRM. Otherwise, SysNAND will\n"
|
||||||
"be booted with an EmuNAND FIRM.\n"
|
"be booted with an EmuNAND FIRM.\n\n"
|
||||||
"To use a different EmuNAND from the\n"
|
"To use a different EmuNAND from the\n"
|
||||||
"default, hold a directional pad button\n"
|
"default, hold a directional pad button\n"
|
||||||
"(Up/Right/Down/Left equal EmuNANDs\n"
|
"(Up/Right/Down/Left equal EmuNANDs\n"
|
||||||
"1/2/3/4)",
|
"1/2/3/4).",
|
||||||
|
|
||||||
"Enable overriding the region and\n"
|
"Enable overriding the region and\n"
|
||||||
"language configuration and the usage\n"
|
"language configuration and the usage\n"
|
||||||
"of patched code binaries for specific\n"
|
"of patched code binaries for specific\n"
|
||||||
"games.\n"
|
"games.\n\n"
|
||||||
"Also makes certain DLCs for\n"
|
"Also makes certain DLCs for\n"
|
||||||
"out-of-region games work.\n"
|
"out-of-region games work.\n\n"
|
||||||
"Refer to the wiki for instructions",
|
"Refer to the wiki for instructions.",
|
||||||
|
|
||||||
"Show the currently booted NAND\n"
|
"Show the currently booted NAND.\n\n"
|
||||||
"(Sys = SysNAND, Emu = EmuNAND 1,\n"
|
"\t* Sys = SysNAND\n"
|
||||||
"EmuX = EmuNAND X,\n"
|
"\t* Emu = EmuNAND 1\n"
|
||||||
"SysE = SysNAND with EmuNAND 1 FIRM,\n"
|
"\t* EmuX = EmuNAND X\n"
|
||||||
"SyEX = SysNAND with EmuNAND X FIRM,\n"
|
"\t* SysE = SysNAND with EmuNAND 1 FIRM\n"
|
||||||
"EmXS = EmuNAND X with SysNAND FIRM)\n"
|
"\t* SyEX = SysNAND with EmuNAND X FIRM\n"
|
||||||
|
"\t* EmXS = EmuNAND X with SysNAND FIRM\n\n"
|
||||||
"or an user-defined custom string in\n"
|
"or an user-defined custom string in\n"
|
||||||
"System Settings.\n"
|
"System Settings.\n\n"
|
||||||
"Refer to the wiki for instructions",
|
"Refer to the wiki for instructions.",
|
||||||
|
|
||||||
"Show the GBA boot screen when booting\n"
|
"Show the GBA boot screen when booting\n"
|
||||||
"GBA games",
|
"GBA games",
|
||||||
@ -155,9 +156,9 @@ void configMenu(bool oldPinStatus)
|
|||||||
"If enabled, the splash screen will be\n"
|
"If enabled, the splash screen will be\n"
|
||||||
"displayed before booting payloads,\n"
|
"displayed before booting payloads,\n"
|
||||||
"otherwise it will be displayed\n"
|
"otherwise it will be displayed\n"
|
||||||
"afterwards.\n"
|
"afterwards.\n\n"
|
||||||
"Intended for splash screens that\n"
|
"Intended for splash screens that\n"
|
||||||
"display button hints"
|
"display button hints."
|
||||||
#ifdef DEV
|
#ifdef DEV
|
||||||
, "Disable SVC, service, archive and ARM9\n"
|
, "Disable SVC, service, archive and ARM9\n"
|
||||||
"exheader access checks"
|
"exheader access checks"
|
||||||
|
@ -76,23 +76,32 @@ void drawCharacter(char character, bool isTopScreen, u32 posX, u32 posY, u32 col
|
|||||||
|
|
||||||
u32 drawString(const char *string, bool isTopScreen, u32 posX, u32 posY, u32 color)
|
u32 drawString(const char *string, bool isTopScreen, u32 posX, u32 posY, u32 color)
|
||||||
{
|
{
|
||||||
for(u32 i = 0, line_i = 0; i < strlen(string); i++, line_i++)
|
for(u32 i = 0, line_i = 0; i < strlen(string); i++)
|
||||||
{
|
{
|
||||||
if(string[i] == '\n')
|
switch(string[i])
|
||||||
{
|
{
|
||||||
posY += SPACING_Y;
|
case '\n':
|
||||||
line_i = 0;
|
posY += SPACING_Y;
|
||||||
i++;
|
line_i = 0;
|
||||||
}
|
break;
|
||||||
else if(line_i >= ((isTopScreen ? SCREEN_TOP_WIDTH : SCREEN_BOTTOM_WIDTH) - posX) / SPACING_X)
|
|
||||||
{
|
case '\t':
|
||||||
//Make sure we never get out of the screen
|
line_i += 2;
|
||||||
posY += SPACING_Y;
|
break;
|
||||||
line_i = 1; //Little offset so we know the same string continues
|
|
||||||
if(string[i] == ' ') i++; //Spaces at the start look weird
|
default:
|
||||||
|
//Make sure we never get out of the screen
|
||||||
|
if(line_i >= ((isTopScreen ? SCREEN_TOP_WIDTH : SCREEN_BOTTOM_WIDTH) - posX) / SPACING_X)
|
||||||
|
{
|
||||||
|
posY += SPACING_Y;
|
||||||
|
line_i = 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
drawCharacter(string[i], isTopScreen, posX + line_i * SPACING_X, posY, color);
|
||||||
|
line_i++;
|
||||||
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
drawCharacter(string[i], isTopScreen, posX + line_i * SPACING_X, posY, color);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
return posY;
|
return posY;
|
||||||
|
Reference in New Issue
Block a user