Difference: 0LASubrWidgetApplyTheme (5 vs. 6)

Revision 62012-03-23 - AlKalter

Line: 1 to 1
 
META TOPICPARENT name="APPXRuntimeSubroutineAPI"

.WIDGET APPLY THEME

Line: 23 to 23
  Finally, you should add a GOSUB to this subroutine in the Global Pre-Display event point of your Inputs and Menus. You can use the .WIDGET MISSING THEME subroutine to help you find these processes.
Changed:
<
<
You can create more than one theme for use in different processes. This is done by first creating another Menu Theme process with the same base name as your main Theme Menu, and then appending a period and some additional characters. For example, you may want you all File Maintenance processes to have a different look from Data Entry processes. You could define 2 additional theme menu processes, one with ".FM" appended to the name, and one with ".DE" appended to the name. In the Input processes where you want to use the ".FM" theme, go to the Image Editor, Window Properties, and put "FM" as the widget name. Do the same for the Data Entry processes. At runtime, the --- .WIDGET APPLY THEME subroutine will notice the widget name, append it to the base name in --- .WIDGET THEME NAME, and use that process as the theme. You could also simply change --- .WIDGET THEME NAME to point to another theme, but since it is Detached, it will retain that new theme until you change it back.
>
>
You can create more than one theme for use in different processes. This is done by first creating another Menu Theme process with the same base name as your main Theme Menu, and then appending a period and some additional characters. For example, you may want all your File Maintenance processes to have a different look from Data Entry processes. You could define 2 additional theme menu processes, one with ".FM" appended to the name, and one with ".DE" appended to the name. In the Input processes where you want to use the ".FM" theme, go to the Image Editor, Window Properties, and put "FM" as the widget name. Do the same for the Data Entry processes. At runtime, the --- .WIDGET APPLY THEME subroutine will notice the widget name, append it to the base name in --- .WIDGET THEME NAME, and use that process as the theme. You could also simply change --- .WIDGET THEME NAME to point to another theme, but since it is Detached, it will retain that new theme until you change it back.
  This subroutine copies micro adjustments, resources, all color settings, fonts, font styles, font sizes, text positions, margins, tiling mode, location type, tooltips, and the settings for the Close, Ok and Help buttons to the GUI attributes of the widgets on the current image. It only replaces default settings, so if you have manually set a font, color or other attribute, that will remain unchanged.
 
This site is powered by the TWiki collaboration platform Powered by PerlCopyright © 2008-2024 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding TWiki? Send feedback