Skip to content

Commit

Permalink
fix: font option style and renderer preference (#3058)
Browse files Browse the repository at this point in the history
* perf: decrease `software` settings priority

nudge `opengl` or `opengles2` over `software` since it's much faster

* style: two spaces for font size options

been conveniently ignoring it for 3 months since  i made the typo in #2728
  • Loading branch information
scarf005 authored Aug 15, 2023
1 parent 49e753a commit 2a348fc
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 9 deletions.
2 changes: 1 addition & 1 deletion src/cata_tiles.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3974,9 +3974,9 @@ std::vector<options_manager::id_and_option> cata_tiles::build_renderer_list()
# if defined(_WIN32)
{ "direct3d", translate_marker( "direct3d" ) },
# endif
{ "software", translate_marker( "software" ) },
{ "opengl", translate_marker( "opengl" ) },
{ "opengles2", translate_marker( "opengles2" ) },
{ "software", translate_marker( "software" ) },
};
int numRenderDrivers = SDL_GetNumRenderDrivers();
DebugLog( DL::Info, DC::Main ) << "Number of render drivers on your system: " << numRenderDrivers;
Expand Down
16 changes: 8 additions & 8 deletions src/options.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1868,14 +1868,14 @@ void options_manager::add_options_graphics()
8, 100, 8, COPT_CURSES_HIDE );

static auto font_size_options = std::array<std::array<std::string, 3>, 8> {{
{"FONT_HEIGHT", translate_marker( "Font height" ), translate_marker( "Set the font height. Requires restart." )},
{"FONT_SIZE", translate_marker( "Font size" ), translate_marker( "Set the font size. Requires restart." )},
{"MAP_FONT_WIDTH", translate_marker( "Map font width" ), translate_marker( "Set the map font width. Requires restart." )},
{"MAP_FONT_HEIGHT", translate_marker( "Map font height" ), translate_marker( "Set the map font height. Requires restart." )},
{"MAP_FONT_SIZE", translate_marker( "Map font size" ), translate_marker( "Set the map font size. Requires restart." )},
{"OVERMAP_FONT_WIDTH", translate_marker( "Overmap font width" ), translate_marker( "Set the overmap font width. Requires restart." )},
{"OVERMAP_FONT_HEIGHT", translate_marker( "Overmap font height" ), translate_marker( "Set the overmap font height. Requires restart." )},
{"OVERMAP_FONT_SIZE", translate_marker( "Overmap font size" ), translate_marker( "Set the overmap font size. Requires restart." )}
{"FONT_HEIGHT", translate_marker( "Font height" ), translate_marker( "Set the font height. Requires restart." )},
{"FONT_SIZE", translate_marker( "Font size" ), translate_marker( "Set the font size. Requires restart." )},
{"MAP_FONT_WIDTH", translate_marker( "Map font width" ), translate_marker( "Set the map font width. Requires restart." )},
{"MAP_FONT_HEIGHT", translate_marker( "Map font height" ), translate_marker( "Set the map font height. Requires restart." )},
{"MAP_FONT_SIZE", translate_marker( "Map font size" ), translate_marker( "Set the map font size. Requires restart." )},
{"OVERMAP_FONT_WIDTH", translate_marker( "Overmap font width" ), translate_marker( "Set the overmap font width. Requires restart." )},
{"OVERMAP_FONT_HEIGHT", translate_marker( "Overmap font height" ), translate_marker( "Set the overmap font height. Requires restart." )},
{"OVERMAP_FONT_SIZE", translate_marker( "Overmap font size" ), translate_marker( "Set the overmap font size. Requires restart." )}
}
};
for( auto &&[option, option_name, option_desc] : font_size_options ) {
Expand Down

0 comments on commit 2a348fc

Please sign in to comment.