Main Help → Browser Style / Using the GEDitCOM Editor→ Universal Browser Style
Good browser styles should written to work in both light and dark models. In general, the only differences between the two modes are defined colors and GEDitCOM II provides a method to define a different color for each mode. In brief, the steps are:
- Develop your browser in light mode. Whenever need to use a color or a font (and fonts include a color), use, or create and use, a named color.
- To add support for dark mode, create a new color or a font for each one created in the first step and append " Dark" (case sensitive) to the name. For example, for the "Editing Background" color, which is usually a light color in light mode, create a color named "Editing Background Dark" and choose a different color, usually a dark color in dark mode. Repeat for all colors and fonts. For fonts, you normally only need to change its color, but may need change font features to match the light mode font.
- All templates in the browser style should refer to defined colors and fonts by the name selected for light mode. When using dark mode, GEDitCOM II will automatically append " Dark" to every name. If a color or font is found, it will be used instead. If not, the original color will be used.
If you want a browser style to look the same in both formats, just use one set of colors (or do not add " Dark" versions of colors and fonts. For some browser styles, this approach works well. But the MacOS may change appearance of various controls used in your browser style. As a result, it still might appear different in the two modes, and one mode might not work well. Such styles should avoid use elements whose appearance is control by the MacOS.