Skip to content

Commit

Permalink
#453 all themes are now based on theme builder.
Browse files Browse the repository at this point in the history
  • Loading branch information
davetcc committed Aug 31, 2024
1 parent d7d4173 commit 477e31e
Show file tree
Hide file tree
Showing 16 changed files with 530 additions and 14 deletions.
4 changes: 2 additions & 2 deletions xmlPlugins/core-themes/CoolBlueModern.xml
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
<TcMenuPlugin name="%theme.cool.blue.modern.name" id="850dc0a3-f534-47c2-94d8-1e64ff368a54"
<TcMenuPlugin name="DEPRECATED - Legacy Cool blue modern theme" id="850dc0a3-f534-47c2-94d8-1e64ff368a54"
subsystem="THEME" requiresDesigner="2.0"
xmlns="https://www.thecoderscorner.com/libraries/tcmenuPluginItem" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="https://www.thecoderscorner.com/libraries/tcmenuPluginItem https://www.thecoderscorner.com/products/arduino-libraries/libraries/tcmenu-plugin-item.xsd">
<SupportedPlatforms>
<All/>
</SupportedPlatforms>
<Description>%theme.cool.blue.modern.desc</Description>
<Description>THIS THEME IS DEPRECATED (kept for existing users), cool blue modern theme</Description>
<Documentation link="https://www.thecoderscorner.com/products/arduino-libraries/tc-menu/themes/color-themes-for-all-display-sizes/"/>
<RequiredLibraries/>
<ImageFile>theme-cool-blue-modern.jpg</ImageFile>
Expand Down
59 changes: 59 additions & 0 deletions xmlPlugins/core-themes/CoolBlueModernBuilder.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,59 @@
<TcMenuPlugin name="%theme.cool.blue.modern.name" id="1947F585-9D36-448C-8A80-B425686107BD"
subsystem="THEME" requiresDesigner="2.0"
xmlns="https://www.thecoderscorner.com/libraries/tcmenuPluginItem" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="https://www.thecoderscorner.com/libraries/tcmenuPluginItem https://www.thecoderscorner.com/products/arduino-libraries/libraries/tcmenu-plugin-item.xsd">
<SupportedPlatforms>
<All/>
</SupportedPlatforms>
<Description>%theme.cool.blue.modern.desc</Description>
<Documentation link="https://www.thecoderscorner.com/products/arduino-libraries/tc-menu/themes/monochrome-themes-for-oled-5110/"/>
<RequiredLibraries/>
<ImageFile>theme-cool-blue-modern.jpg</ImageFile>

<Properties>
<Property id="ITEM_FONT" name="%theme.item.font" initial="def:,1" desc="%theme.item.font.desc" type="font"/>
<Property id="TITLE_FONT" name="%theme.title.font" initial="def:,1" desc="%theme.title.font.desc" type="font"/>
<Property id="BORDER_FOR_ACTIONS" name="%theme.border.for.action" initial="0" desc="%theme.border.for.action.desc" type="int" min="0" max="3"/>
<Property id="TITLE_SHOW_MODE" name="%theme.title.show.mode" initial="TITLE_FIRST_ROW" desc="%theme.title.show.mode.desc" type="choice">
<Choices>
<Choice desc="%theme.title.none">NO_TITLE</Choice>
<Choice desc="%theme.title.first.row">TITLE_FIRST_ROW</Choice>
<Choice desc="%theme.title.always">TITLE_ALWAYS</Choice>
</Choices>
</Property>
<Property id="USE_TC_UNICODE" name="%theme.use.tcunicode" initial="false" type="boolean" desc="%theme.use.tcunicode.desc"/>
<Property id="USE_SLIDER_ANALOG" name="%theme.use.sliders" initial="true" desc="%theme.use.sliders.desc" type="boolean"/>
<Property id="NEED_EDITING_ICONS" name="%theme.need.edit.icons" initial="false" desc="theme.need.edit.icons.desc" type="boolean"/>
</Properties>

<ApplicabilityDefs/>

<SourceFiles>
<Replacement find="USE_SLIDER_FOR_ANALOG 1" replace="USE_SLIDER_FOR_ANALOG ${USE_SLIDER_ANALOG}"/>
<Replacement find="ACTION_BORDER_WIDTH 0" replace="ACTION_BORDER_WIDTH ${BORDER_FOR_ACTIONS}"/>
<SourceFile name="coolBlue/ThemeCoolBlueModernBuilder.h" overwrite="false"/>
</SourceFiles>

<IncludeFiles>
<Header name="${SRC_DIR_OFFSET}ThemeCoolBlueModernBuilder.h" inSource="cppSrc"/>
<Header name="tcUnicodeHelper.h" inSource="false" priority="high" whenProperty="USE_TC_UNICODE" isValue="true" />
<Header name="${ITEM_FONT}" inSource="font"/>
<Header name="${TITLE_FONT}" inSource="font"/>
</IncludeFiles>

<GlobalVariables>
<Variable name="${ITEM_FONT}" export="font" whenProperty="ITEM_FONT" matches="ad[al]:.*" />
<Variable name="${TITLE_FONT}" export="font" whenProperty="ITEM_FONT" matches="ad[al]:.*" />
</GlobalVariables>

<SetupFunctions>
<Function name="installDarkModeModernTheme">
<Param value="renderer"/>
<Param font="${ITEM_FONT}"/>
<Param font="${TITLE_FONT}"/>
<Param value="${NEED_EDITING_ICONS}"/>
<Param name="BaseGraphicalRenderer::${TITLE_SHOW_MODE}"/>
<Param name="${USE_TC_UNICODE}"/>
</Function>
</SetupFunctions>
</TcMenuPlugin>
4 changes: 2 additions & 2 deletions xmlPlugins/core-themes/CoolBlueTraditional.xml
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
<TcMenuPlugin name="%theme.cool.blue.traditional.name" id="03c6b25f-db63-402a-8447-a5ce1484c14d"
<TcMenuPlugin name="DEPRECATED cool blue traditional" id="03c6b25f-db63-402a-8447-a5ce1484c14d"
subsystem="THEME" requiresDesigner="2.0"
xmlns="https://www.thecoderscorner.com/libraries/tcmenuPluginItem" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="https://www.thecoderscorner.com/libraries/tcmenuPluginItem https://www.thecoderscorner.com/products/arduino-libraries/libraries/tcmenu-plugin-item.xsd">
<SupportedPlatforms>
<All/>
</SupportedPlatforms>
<Description>%theme.cool.blue.traditional.desc</Description>
<Description>THIS THEME IS DEPRECATED (kept for existing users), cool blue traditional theme</Description>
<Documentation link="https://www.thecoderscorner.com/products/arduino-libraries/tc-menu/themes/color-themes-for-all-display-sizes/"/>
<RequiredLibraries/>
<ImageFile>theme-cool-blue-traditional.jpg</ImageFile>
Expand Down
55 changes: 55 additions & 0 deletions xmlPlugins/core-themes/CoolBlueTraditionalBuilder.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,55 @@
<TcMenuPlugin name="%theme.cool.blue.traditional.name" id="57945787-0A04-447B-BBA2-6461FC505397"
subsystem="THEME" requiresDesigner="2.0"
xmlns="https://www.thecoderscorner.com/libraries/tcmenuPluginItem" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="https://www.thecoderscorner.com/libraries/tcmenuPluginItem https://www.thecoderscorner.com/products/arduino-libraries/libraries/tcmenu-plugin-item.xsd">
<SupportedPlatforms>
<All/>
</SupportedPlatforms>
<Description>%theme.cool.blue.traditional.desc</Description>
<Documentation link="https://www.thecoderscorner.com/products/arduino-libraries/tc-menu/themes/color-themes-for-all-display-sizes/"/>
<RequiredLibraries/>
<ImageFile>theme-cool-blue-traditional.jpg</ImageFile>

<Properties>
<Property id="ITEM_FONT" name="%theme.item.font" initial="def:,1" desc="%theme.item.font.desc" type="font"/>
<Property id="TITLE_FONT" name="%theme.title.font" initial="def:,1" desc="%theme.title.font.desc" type="font"/>
<Property id="TITLE_SHOW_MODE" name="%theme.title.show.mode" initial="TITLE_FIRST_ROW" desc="%theme.title.show.mode.desc" type="choice">
<Choices>
<Choice desc="%theme.title.none">NO_TITLE</Choice>
<Choice desc="%theme.title.first.row">TITLE_FIRST_ROW</Choice>
<Choice desc="%theme.title.always">TITLE_ALWAYS</Choice>
</Choices>
</Property>
<Property id="USE_TC_UNICODE" name="%theme.use.tcunicode" initial="false" type="boolean" desc="%theme.use.tcunicode.desc"/>
<Property id="NEED_EDITING_ICONS" name="%theme.need.edit.icons" initial="false" desc="theme.need.edit.icons.desc" type="boolean"/>
</Properties>

<ApplicabilityDefs/>

<SourceFiles>
<SourceFile name="coolBlue/ThemeCoolBlueTraditionalBuilder.h" overwrite="false"/>
</SourceFiles>

<IncludeFiles>
<Header name="${SRC_DIR_OFFSET}ThemeCoolBlueTraditionalBuilder.h" inSource="cppSrc"/>
<Header name="tcUnicodeHelper.h" inSource="false" priority="high" whenProperty="USE_TC_UNICODE" isValue="true" />
<Header name="${ITEM_FONT}" inSource="font"/>
<Header name="${TITLE_FONT}" inSource="font"/>
</IncludeFiles>

<GlobalVariables>
<Variable name="${ITEM_FONT}" export="font" whenProperty="ITEM_FONT" matches="ad[al]:.*" />
<Variable name="${TITLE_FONT}" export="font" whenProperty="ITEM_FONT" matches="ad[al]:.*" />
</GlobalVariables>

<SetupFunctions>
<Function name="installCoolBlueTraditionalTheme">
<Param value="renderer"/>
<Param font="${ITEM_FONT}"/>
<Param font="${TITLE_FONT}"/>
<Param value="${NEED_EDITING_ICONS}"/>
<Param name="BaseGraphicalRenderer::${TITLE_SHOW_MODE}"/>
<Param name="${USE_TC_UNICODE}"/>
</Function>
</SetupFunctions>
</TcMenuPlugin>
4 changes: 2 additions & 2 deletions xmlPlugins/core-themes/DarkModeModern.xml
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
<TcMenuPlugin name="%theme.dark.modern.name" id="e3d447ef-a620-47fa-9a3c-012665b30bdf"
<TcMenuPlugin name="DEPRECATED dark mode modern theme" id="e3d447ef-a620-47fa-9a3c-012665b30bdf"
subsystem="THEME" requiresDesigner="2.0"
xmlns="https://www.thecoderscorner.com/libraries/tcmenuPluginItem" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="https://www.thecoderscorner.com/libraries/tcmenuPluginItem https://www.thecoderscorner.com/products/arduino-libraries/libraries/tcmenu-plugin-item.xsd">
<SupportedPlatforms>
<All/>
</SupportedPlatforms>
<Description>%theme.dark.modern.desc</Description>
<Description>THIS THEME IS DEPRECATED (kept for existing users), dark mode modern theme</Description>
<Documentation link="https://www.thecoderscorner.com/products/arduino-libraries/tc-menu/themes/dark-themes-for-all-display-sizes/"/>
<RequiredLibraries/>
<ImageFile>theme-dark-mode-modern.jpg</ImageFile>
Expand Down
59 changes: 59 additions & 0 deletions xmlPlugins/core-themes/DarkModeModernBuilder.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,59 @@
<TcMenuPlugin name="%theme.dark.modern.name" id="94D05CB2-952F-4E0C-A402-9F51CAFBD99E"
subsystem="THEME" requiresDesigner="2.0"
xmlns="https://www.thecoderscorner.com/libraries/tcmenuPluginItem" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="https://www.thecoderscorner.com/libraries/tcmenuPluginItem https://www.thecoderscorner.com/products/arduino-libraries/libraries/tcmenu-plugin-item.xsd">
<SupportedPlatforms>
<All/>
</SupportedPlatforms>
<Description>%theme.dark.modern.desc</Description>
<Documentation link="https://www.thecoderscorner.com/products/arduino-libraries/tc-menu/themes/dark-themes-for-all-display-sizes/"/>
<RequiredLibraries/>
<ImageFile>theme-dark-mode-modern.jpg</ImageFile>

<Properties>
<Property id="ITEM_FONT" name="%theme.item.font" initial="def:,1" desc="%theme.item.font.desc" type="font"/>
<Property id="TITLE_FONT" name="%theme.title.font" initial="def:,1" desc="%theme.title.font.desc" type="font"/>
<Property id="BORDER_FOR_ACTIONS" name="%theme.border.for.action" initial="0" desc="%theme.border.for.action.desc" type="int" min="0" max="3"/>
<Property id="TITLE_SHOW_MODE" name="%theme.title.show.mode" initial="TITLE_FIRST_ROW" desc="%theme.title.show.mode.desc" type="choice">
<Choices>
<Choice desc="%theme.title.none">NO_TITLE</Choice>
<Choice desc="%theme.title.first.row">TITLE_FIRST_ROW</Choice>
<Choice desc="%theme.title.always">TITLE_ALWAYS</Choice>
</Choices>
</Property>
<Property id="USE_TC_UNICODE" name="%theme.use.tcunicode" initial="false" type="boolean" desc="%theme.use.tcunicode.desc"/>
<Property id="USE_SLIDER_ANALOG" name="%theme.use.sliders" initial="true" desc="%theme.use.sliders.desc" type="boolean"/>
<Property id="NEED_EDITING_ICONS" name="%theme.need.edit.icons" initial="false" desc="theme.need.edit.icons.desc" type="boolean"/>
</Properties>

<ApplicabilityDefs/>

<SourceFiles>
<Replacement find="USE_SLIDER_FOR_ANALOG 1" replace="USE_SLIDER_FOR_ANALOG ${USE_SLIDER_ANALOG}"/>
<Replacement find="ACTION_BORDER_WIDTH 0" replace="ACTION_BORDER_WIDTH ${BORDER_FOR_ACTIONS}"/>
<SourceFile name="darkMode/ThemeDarkModeModernBuilder.h" overwrite="false"/>
</SourceFiles>

<IncludeFiles>
<Header name="${SRC_DIR_OFFSET}ThemeDarkModeModernBuilder.h" inSource="cppSrc"/>
<Header name="tcUnicodeHelper.h" inSource="false" priority="high" whenProperty="USE_TC_UNICODE" isValue="true" />
<Header name="${ITEM_FONT}" inSource="font"/>
<Header name="${TITLE_FONT}" inSource="font"/>
</IncludeFiles>

<GlobalVariables>
<Variable name="${ITEM_FONT}" export="font" whenProperty="ITEM_FONT" matches="ad[al]:.*" />
<Variable name="${TITLE_FONT}" export="font" whenProperty="ITEM_FONT" matches="ad[al]:.*" />
</GlobalVariables>

<SetupFunctions>
<Function name="installDarkModeModernTheme">
<Param value="renderer"/>
<Param font="${ITEM_FONT}"/>
<Param font="${TITLE_FONT}"/>
<Param value="${NEED_EDITING_ICONS}"/>
<Param name="BaseGraphicalRenderer::${TITLE_SHOW_MODE}"/>
<Param name="${USE_TC_UNICODE}"/>
</Function>
</SetupFunctions>
</TcMenuPlugin>
4 changes: 2 additions & 2 deletions xmlPlugins/core-themes/DarkModeTraditional.xml
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
<TcMenuPlugin name="%theme.dark.traditional.name" id="e4524028-edd8-4e0a-ae15-a1f2ba05354f"
<TcMenuPlugin name="DEPRECATED - dark mode traditional theme" id="e4524028-edd8-4e0a-ae15-a1f2ba05354f"
subsystem="THEME" requiresDesigner="2.0"
xmlns="https://www.thecoderscorner.com/libraries/tcmenuPluginItem" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="https://www.thecoderscorner.com/libraries/tcmenuPluginItem https://www.thecoderscorner.com/products/arduino-libraries/libraries/tcmenu-plugin-item.xsd">
<SupportedPlatforms>
<All/>
</SupportedPlatforms>
<Description>%theme.dark.traditional.desc</Description>
<Description>THIS THEME IS DEPRECATED (kept for existing users), dark mode traditional theme</Description>
<Documentation link="https://www.thecoderscorner.com/products/arduino-libraries/tc-menu/themes/dark-themes-for-all-display-sizes/"/>
<RequiredLibraries/>
<ImageFile>theme-dark-mode-traditional.jpg</ImageFile>
Expand Down
54 changes: 54 additions & 0 deletions xmlPlugins/core-themes/DarkModeTraditionalBuilder.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,54 @@
<TcMenuPlugin name="%theme.dark.traditional.name" id="2F1EAB1E-0469-42C8-A222-BE2DF96D6D81"
subsystem="THEME" requiresDesigner="2.0"
xmlns="https://www.thecoderscorner.com/libraries/tcmenuPluginItem" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="https://www.thecoderscorner.com/libraries/tcmenuPluginItem https://www.thecoderscorner.com/products/arduino-libraries/libraries/tcmenu-plugin-item.xsd">
<SupportedPlatforms>
<All/>
</SupportedPlatforms>
<Description>%theme.dark.traditional.desc</Description>
<Documentation link="https://www.thecoderscorner.com/products/arduino-libraries/tc-menu/themes/dark-themes-for-all-display-sizes/"/>
<RequiredLibraries/>
<ImageFile>theme-dark-mode-traditional.jpg</ImageFile>

<Properties>
<Property id="ITEM_FONT" name="%theme.item.font" initial="def:,1" desc="%theme.item.font.desc" type="font"/>
<Property id="TITLE_FONT" name="%theme.title.font" initial="def:,1" desc="%theme.title.font.desc" type="font"/>
<Property id="TITLE_SHOW_MODE" name="%theme.title.show.mode" initial="TITLE_FIRST_ROW" desc="%theme.title.show.mode.desc" type="choice">
<Choices>
<Choice desc="%theme.title.none">NO_TITLE</Choice>
<Choice desc="%theme.title.first.row">TITLE_FIRST_ROW</Choice>
<Choice desc="%theme.title.always">TITLE_ALWAYS</Choice>
</Choices>
</Property>
<Property id="USE_TC_UNICODE" name="%theme.use.tcunicode" initial="false" type="boolean" desc="%theme.use.tcunicode.desc"/>
<Property id="NEED_EDITING_ICONS" name="%theme.need.edit.icons" initial="false" desc="theme.need.edit.icons.desc" type="boolean"/> </Properties>

<ApplicabilityDefs/>

<SourceFiles>
<SourceFile name="darkMode/ThemeDarkModeTraditionalBuilder.h" overwrite="false"/>
</SourceFiles>

<IncludeFiles>
<Header name="${SRC_DIR_OFFSET}ThemeDarkModeTraditionalBuilder.h" inSource="cppSrc"/>
<Header name="tcUnicodeHelper.h" inSource="false" priority="high" whenProperty="USE_TC_UNICODE" isValue="true" />
<Header name="${ITEM_FONT}" inSource="font"/>
<Header name="${TITLE_FONT}" inSource="font"/>
</IncludeFiles>

<GlobalVariables>
<Variable name="${ITEM_FONT}" export="font" whenProperty="ITEM_FONT" matches="ad[al]:.*" />
<Variable name="${TITLE_FONT}" export="font" whenProperty="ITEM_FONT" matches="ad[al]:.*" />
</GlobalVariables>

<SetupFunctions>
<Function name="installDarkModeTraditionalTheme">
<Param value="renderer"/>
<Param font="${ITEM_FONT}"/>
<Param font="${TITLE_FONT}"/>
<Param value="${NEED_EDITING_ICONS}"/>
<Param name="BaseGraphicalRenderer::${TITLE_SHOW_MODE}"/>
<Param name="${USE_TC_UNICODE}"/>
</Function>
</SetupFunctions>
</TcMenuPlugin>
2 changes: 1 addition & 1 deletion xmlPlugins/core-themes/MonoInverseTitle.xml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
<SupportedPlatforms>
<All/>
</SupportedPlatforms>
<Description>THIS THEME IS DEPRECATED (kept existing users), mono inverse theme for lower resolution.</Description>
<Description>THIS THEME IS DEPRECATED (kept for existing users), mono inverse theme for lower resolution.</Description>
<Documentation link="https://www.thecoderscorner.com/products/arduino-libraries/tc-menu/themes/monochrome-themes-for-oled-5110/"/>
<RequiredLibraries/>
<ImageFile>theme-oled-inverse.jpg</ImageFile>
Expand Down
Loading

0 comments on commit 477e31e

Please sign in to comment.