* Implemented Theme Menu. * Minor adjustments. * added two new theming attributes, borderColor, borderTextcolor, allows users to modify the boxes that surrounds the menu entries * added theme info to config file, users can now add theme author, theme name, and theme version to a theme config file. * tested building on mac osx, added to .gitignore and make clean for files generated on osx * The path for the theme is now stored in a config string in settings.cfg, instead of a hard-coded theme.cfg path. * added functions to create/modify settings config for hbmenu theme * added Default theme entry that will always insert itself at the front of the list of themes * added code for + and - button, using - button for theme menu now (button display for this is disabled).
39 lines
858 B
C
39 lines
858 B
C
#pragma once
|
|
|
|
#include "common.h"
|
|
#include <libconfig.h>
|
|
|
|
typedef struct
|
|
{
|
|
color_t textColor;
|
|
color_t frontWaveColor;
|
|
color_t middleWaveColor;
|
|
color_t backWaveColor;
|
|
color_t backgroundColor;
|
|
color_t highlightColor;
|
|
color_t separatorColor;
|
|
color_t borderColor;
|
|
color_t borderTextColor;
|
|
bool enableWaveBlending;
|
|
char buttonAText[32];
|
|
char buttonBText[32];
|
|
char buttonPText[32];
|
|
char buttonMText[32];
|
|
const uint8_t *hbmenuLogoImage;
|
|
} theme_t;
|
|
|
|
typedef enum
|
|
{
|
|
THEME_PRESET_LIGHT,
|
|
THEME_PRESET_DARK,
|
|
} ThemePreset;
|
|
|
|
bool colorFromSetting(config_setting_t *rgba, color_t *col);
|
|
void themeStartup(ThemePreset preset);
|
|
void GetThemePathFromConfig(char* themePath, size_t size);
|
|
void SetThemePathToConfig(const char* themePath);
|
|
|
|
extern theme_t themeCurrent;
|
|
|
|
extern ThemePreset themeGlobalPreset;
|