Differences

This shows you the differences between two versions of the page.

Link to this comparison view

dglux5_wiki:workspace_and_workflow:panels_and_menus:widget_palette [2019/07/17 19:17] (current)
Line 1: Line 1:
 +{{indexmenu_n>​12}}
 +====== Widget Palette ======
 +You can use the widget palette to keep [[dglux5_wiki:​widgets_and_property_inspector:​essentials:​home|widgets]] consistent across projects and team members. This page covers creating and importing libraries for the widget palette. For details about creating and editing widgets, see [[dglux5_wiki:​widgets_and_property_inspector:​essentials:​home|Component and Widget Essentials]].
  
 +The widget palette is located at the bottom of the workspace. The widget palette contains all of the widget libraries that have been created in this project or that have been imported to this project from other projects. In other words, the palette contains everything that is stored in the ''​palette''​ and ''​lib''​ [[dglux5_wiki:​workspace_and_workflow:​projects_and_files:​project_directories|directories]] for this project.
 +
 +{{:​dglux5_wiki:​workspace_and_workflow:​dglux5_widget_palette_4.png?​direct|}}\\
 +//The DGLux5 widget palette.//
 +
 +----
 +
 +==== Video Tutorial: Adding and Removing Libraries ====
 +
 +<​html>​
 +<​left>​
 +<iframe width="​620"​ height="​350"​ src="​http://​player.vimeo.com/​video/​118835190"​ frameborder="​0"​ allowfullscreen></​iframe>​
 +</​left>​
 +</​html>​
 +
 +More video tutorials are [[http://​dglogik.com/​videos|here]].
 +
 +----
 +
 +===== Create Your Own Widget Library =====
 +To build your own widget library:
 +
 +  - Open the ''​.dg5''​ file that contains the widgets you want to use. 
 +  - Select **File** > **Save As**. 
 +  - Save the file in the ''​palette''​ [[dglux5_wiki:​workspace_and_workflow:​projects_and_files:​project_directories#​palette|directory]]. Give it the name that you want to appear in the widget palette.
 +  - <​WRAP>​Refresh your browser.
 +
 +In the widget palette, the name of this file becomes a category under the name of the current project.
 +
 +Click a category to expand it and see its available widgets. If needed, use the scrollbar to see all available widgets and categories.
 +
 +{{:​dglux5_wiki:​workspace_and_workflow:​dglux5_widget_palette_2.png?​direct|}}\\
 +//The files named// ''​1''//,//​ ''​2''//,​ and// ''​3''​ //were saved to the// ''​palette''​ //directory and are categories in the widget palette.//</​WRAP>​
 +
 +----
 +
 +===== Import a Widget Library =====
 +To import widget libraries from other projects:
 +
 +  - Select the ''​lib''​ [[dglux5_wiki:​workspace_and_workflow:​projects_and_files:​project_directories|directory]] in the [[dglux5_wiki:​workspace_and_workflow:​panels_and_menus:​project_panel|Project panel]].
 +  - <​WRAP>​Right-click the ''​lib''​ directory, and select **Import Library**.
 +
 + ​{{:​dglux5_wiki:​workspace_and_workflow:​dglux5_widget_palette_1.png?​direct|}}
 +
 +A list of the other projects to which you have access appears.</​WRAP>​
 +  - Select the project that contains the widgets you want. Select multiple projects by holding Ctrl on Windows or Command on Mac. 
 +  - <​WRAP>​Click **Import**.
 +
 +Each project appears as a folder in your ''​lib''​ directory and a category in your widget palette.
 +
 + ​{{:​dglux5_wiki:​workspace_and_workflow:​dglux5_widget_palette_3.png?​direct|}}\\
 +//The libraries for the// ''​DGBox''//,//​ ''​Dashboard''//,​ and// ''​HVAC''​ //projects were imported to the// ''​lib''​ //​directory. The// ''​Dashboard''​ //library is selected in the palette. The// ''​Dashboard''​ //library includes the sub-categories//​ ''​Charts''​ //and// ''​Gauges''​.</​WRAP>​
 +
 +<WRAP tip>=== Tip: Use Templates to Simplify Access to Widgets ===
 +When you save a project as a [[dglux5_wiki:​workspace_and_workflow:​projects_and_files:​home#​using_project_templates|template]],​ you can use the template to quickly access all of the relevant widget libraries without having to import or re-create them.</​WRAP>​
 +
 +----
 +
 +===== Edit Widgets =====
 +You edit a widget using its [[dglux5_wiki:​widgets_and_property_inspector:​property_inspector:​home|properties]]. For more information,​ see [[dglux5_wiki:​widgets_and_property_inspector:​essentials:​home|Component and Widget Essentials]].
 +
 +You can edit a widget in three different places, with different results:
 +
 +^ Place where you edit the widget ^ Places affected ^
 +|The ''​palette''​ [[dglux5_wiki:​workspace_and_workflow:​projects_and_files:​project_directories|directory]] that owns the widget|<​WRAP>​
 +  * This ''​palette''​ directory
 +  * All ''​lib''​ directories into which this widget’s ''​.dg5''​ file has been [[#​import_a_widget_library|imported]]
 +  * Therefore, all widget palettes that include this widget
 +</​WRAP>​|
 +|A ''​lib''​ directory where the widget has been imported|<​WRAP>​
 +  * This ''​lib''​ directory
 +  * Therefore, the widget palette in this project
 +</​WRAP>​|
 +|Any other ''​.dg5''​ file where an instance of the widget has been created using the widget palette|<​WRAP>​
 +  * This instance only
 +</​WRAP>​|
 +
 +<WRAP info>​===Note===
 +[[dglux5_wiki:​widgets_and_property_inspector:​components:​symbols:​home|Symbols]] are the exception to this rule. If the widget is a symbol, and you have ''​can edit''​ access to the source file, then you can enter [[dglux5_wiki:​widgets_and_property_inspector:​components:​symbols:​home#​edit_a_symbol|symbol editing mode]] to edit the source symbol. Changes made in symbol editing mode affect the source symbol and all instances of the symbol.</​WRAP>​
 +
 +<WRAP tip>​===Tip===
 +Sometimes, you might want to put a widget from another project into your widget palette, while also ensuring that the widget in your palette is unaffected by edits to the original widget. To achieve this effect:
 +  - Make sure you have access to the project that owns the widget. You can ask the creator for access.
 +  - [[dglux5_wiki:​workspace_and_workflow:​projects_and_files:​import_dg5|Import a copy]] of the ''​.dg5''​ file that contains the widget.
 +  - [[dglux5_wiki:​workspace_and_workflow:​projects_and_files:​about_dg5#​save_a_dg5_file|Save]] the imported file in your ''​palette''​ directory. ​
 +
 +Keep in mind that if you do this, your file is not in sync with the source file, and you will not receive any updates to this file.</​WRAP>​
 +
 +----
 +===== Set Widget Palette Icon =====
 +If a widget is a symbol, you can set the icon that represents the widget in any widget palette panel. To set the icon:
 +  - Open the ''​palette''​ directory in the project that owns the widget.
 +  - Make sure that the widget is a symbol.
 +  - Make sure that the icon is uploaded to the project.
 +  - With the symbol selected, in the [[advanced_panel|Advanced Properties]] panel, set the **paletteIcon** property as the path to the icon.
 +
 +----
 +
 +===== More Resources =====
 +  * [[http://​www.dglogik.com/​index.php/​videos/​adding-and-removing-libraries | Adding and Removing Libraries]] (video)
 +  * [[https://​vimeo.com/​121496103 | Customizing Libraries in Application Platform]] (video)
 +
 +----
 +
 +<WRAP left>​[[dglux5_wiki:​workspace_and_workflow:​panels_and_menus:​tools_panel|Previous:​ Tools Panel and Quick Access Panel]]</​WRAP>​
 +<WRAP right>​[[dglux5_wiki:​workspace_and_workflow:​panels_and_menus:​favorites_popup|Next:​ Favorites Pop-Ups]]</​WRAP>​