Customize Toolbars: Difference between revisions

From FreeCAD Documentation
(Create page)
 
No edit summary
(22 intermediate revisions by 6 users not shown)
Line 1: Line 1:
<languages/>
{{TutorialInfo|Class=SampleClass|Level=Beginner|Time=5 minutes|Author=[[User:Mario52|Mario52]]|FCVersion=Alls}}
<translate>
<!--T:1-->
{{TutorialInfo|Topic=SampleTopic|Level=Beginner|Time=5 minutes|Author=[[User:Mario52|Mario52]]|FCVersion=All}}


===Synopsis===
==Synopsis== <!--T:2-->
This tutorial shows you the customization of toolbars. Tools (inclusive Macro-tools) can used in different workbenches. In an example a Macro becomes a Macro-tool by creation of a '''Menu text''', a '''Tool tip''' and an '''Icon'''. Afterwards this Macro-tool becomes part of an extra toolbar in a workbench.


==Use== <!--T:3-->
This tutorial walks you through how to create a Toolbar button and one or more that connect you to your favorite macros or other links assiciant there a custom icon or not.
<u>'''1.''' Find the Customize Menu</u>


<!--T:4-->
===Uses===
*Click {{MenuCommand|Main Menu → Tools → Customize}},


<!--T:5-->
1 click rigth and click the menu Customize
[[File:CustomizeToolBar 01.png|640px|center|Customize]]
{{clear}}


<!--T:6-->
or Menu Tools Customize
*or right click on any toolbar.


<!--T:7-->
one window Customize appears
[[File:CustomizeToolBar 02.png|640px|center|Right mouse click]]
{{clear}}


<!--T:8-->
2 select the menu Macro
*The Customize window appears.


<!--T:9-->
3 click Pixmap button ...
[[File:CustomizeToolBar 03.png|640px|center|The Customize window appears]]
{{clear}}


<!--T:52-->
4 search your icon if your icon is not here
<u>'''2.''' Make a Macro to a Macro-Tool</u>


<!--T:10-->
5 click the button Add icons... for adding icones of window
*Select the "Macro" tab.


<!--T:11-->
6 select your icon
*To add an icon for the provided macro click the Pixmap button (labelled {{KEY|... }}).


<!--T:12-->
7 Choice your macro and specify one Menu text and other informations for your Button
[[File:CustomizeToolBar 04.png|640px|center|Select a toolbar]]
{{clear}}


<!--T:13-->
8 Click the button Add
*Search for an appropriate icon from amongst FreeCAD's existing icons,


<!--T:47-->
9 your button is create
<div class="mw-collapsible mw-collapsed toccolours">


<!--T:48-->
10 create one Toolbar for the button
&nbsp; &nbsp; &nbsp; [or add your own icon by clicking {{KEY|Add icons...}}]. &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;(expand for an example)


<!--T:49-->
11 Click the menu Toolbars
<div class="mw-collapsible-content">


<!--T:14-->
12 window left select Macros in the menu
[[File:CustomizeToolBar 05.png|640px|center|Add icon]]
{{clear}}


<!--T:15-->
13 your icon appears
&nbsp; &nbsp; &nbsp;[You will get a file selection window, select your custom image file (PNG format, 64x64 pixels)]


<!--T:16-->
14 Click the buttom New...
[[File:CustomizeToolBar 06.png|640px|center|Get a file]]
{{clear}}


<!--T:50-->
15 in the window give the name and validate
</div>
</div>


<!--T:17-->
16 your tool bar is created select t your button of left and click the arrow right
* Select your icon and click {{KEY|OK}}.


<!--T:18-->
17 your button is associated of the Toolbar Camera
[[File:CustomizeToolBar 07.png|640px|center|Select your icon]]
{{clear}}


<!--T:19-->
18 click the button Close
* The icon you selected is now displayed next to the Pixmap button labelled {{KEY|...}}.


<!--T:20-->
19 your ToolBar is here whit your Button
[[File:CustomizeToolBar 08.png|640px|center|Your icon is displayed]]
{{clear}}


<!--T:21-->
20 enjoy !
*Select the provided macro in line '''Macro:''' and specify a '''Menu text''': (which will appear as the text label in the menu); also fill in the '''Tool Tip':'' (which is the text that will appear when a mouse is over the button on the toolbar); further lines are optional.


<!--T:22-->
* Click the button {{KEY|Add}}.


<!--T:23-->
[[File:CustomizeToolBar 09.png|640px|center|Click the button]]
{{clear}}


<!--T:24-->
[[Category:Tutorials]]
*The button of the macro-tool is now created.

<!--T:25-->
[[File:CustomizeToolBar 10.png|640px|center|Your button is created]]
{{clear}}

<!--T:26-->
<u>'''3.''' Create a toolbar outside the workbench '''Macro''' which contains the created '''Macro-tool'''</u>

<!--T:27-->
* Select the '''Toolbars''' tab and choose the workbench (for which the toolbar is provided) in the drop down on the right ('''Part''' in this example).

<!--T:51-->
&nbsp; &nbsp; &nbsp;[Since version 0.15 there is a &nbsp;{{KEY|[[File:Freecad.svg|16px]] Global}}&nbsp; toolbar. If this is selected, the provided toolbar will be in each workbench.]

<!--T:28-->
[[File:CustomizeToolBar 11.png|640px|center|Toolbars tab]]
{{clear}}

<!--T:29-->
*In the dropdown on the left select '''Macros'''.

<!--T:30-->
[[File:CustomizeToolBar 12.png|640px|center|Macros]]
{{clear}}

<!--T:31-->
*The macro-tool with its icon appears in the list.

<!--T:32-->
[[File:CustomizeToolBar 13.png|640px|center|Your icon is listed]]
{{clear}}

<!--T:33-->
*Click the button {{KEY|New...}}

<!--T:34-->
[[File:CustomizeToolBar 14.png|640px|center|Click on "New"]]
{{clear}}

<!--T:35-->
*In the window "New Toolbar" enter the name of the provided extra toolbar for the '''Part''' Workbench and click {{KEY|OK}}

<!--T:36-->
[[File:CustomizeToolBar 15.png|640px|center|Enter the name for your toolbar]]
{{clear}}

<!--T:37-->
*The toolbar is now created.

<!--T:38-->
*To add the creadet macro-tool to this toolbar, select it in the left window and then click the {{KEY|Button}} with the arrow pointing right.

<!--T:39-->
[[File:CustomizeToolBar 16.png|640px|center|Select your macro]]
{{clear}}

<!--T:40-->
* You have created now a toolbar called "Camera" (with the Macro-tool '''Camera''' in it)

<!--T:41-->
*Click the {{KEY|Close}} button.

<!--T:42-->
[[File:CustomizeToolBar 17.png|640px|center|Close]]
{{clear}}

<!--T:43-->
*Your new toolbar is now contained in the toolbars' right-click menu. Its Icons (in our example only the camera) are visible, if the toolbar is activated (blue checkmark).

<!--T:44-->
[[File:CustomizeToolBar 18.png|640px|center|New Toolbar]]
{{clear}}


</translate>
{{clear}}

Revision as of 20:17, 2 August 2018

Tutorial
Topic
SampleTopic
Level
Beginner
Time to complete
5 minutes
Authors
Mario52
FreeCAD version
All
Example files
None
See also
None

Synopsis

This tutorial shows you the customization of toolbars. Tools (inclusive Macro-tools) can used in different workbenches. In an example a Macro becomes a Macro-tool by creation of a Menu text, a Tool tip and an Icon. Afterwards this Macro-tool becomes part of an extra toolbar in a workbench.

Use

1. Find the Customize Menu

  • Click Main Menu → Tools → Customize,
Customize
Customize
  • or right click on any toolbar.
Right mouse click
Right mouse click
  • The Customize window appears.
The Customize window appears
The Customize window appears

2. Make a Macro to a Macro-Tool

  • Select the "Macro" tab.
  • To add an icon for the provided macro click the Pixmap button (labelled ... ).
Select a toolbar
Select a toolbar
  • Search for an appropriate icon from amongst FreeCAD's existing icons,

      [or add your own icon by clicking Add icons...].                  (expand for an example)

Add icon
Add icon

     [You will get a file selection window, select your custom image file (PNG format, 64x64 pixels)]

Get a file
Get a file
  • Select your icon and click OK.
Select your icon
Select your icon
  • The icon you selected is now displayed next to the Pixmap button labelled ....
Your icon is displayed
Your icon is displayed
  • Select the provided macro in line Macro:' and specify a Menu text: (which will appear as the text label in the menu); also fill in the Tool Tip': (which is the text that will appear when a mouse is over the button on the toolbar); further lines are optional.
  • Click the button Add.
Click the button
Click the button
  • The button of the macro-tool is now created.
Your button is created
Your button is created

3. Create a toolbar outside the workbench Macro which contains the created Macro-tool

  • Select the Toolbars tab and choose the workbench (for which the toolbar is provided) in the drop down on the right (Part in this example).

     [Since version 0.15 there is a   Global  toolbar. If this is selected, the provided toolbar will be in each workbench.]

Toolbars tab
Toolbars tab
  • In the dropdown on the left select Macros.
Macros
Macros
  • The macro-tool with its icon appears in the list.
Your icon is listed
Your icon is listed
  • Click the button New...
Click on "New"
Click on "New"
  • In the window "New Toolbar" enter the name of the provided extra toolbar for the Part Workbench and click OK
Enter the name for your toolbar
Enter the name for your toolbar
  • The toolbar is now created.
  • To add the creadet macro-tool to this toolbar, select it in the left window and then click the Button with the arrow pointing right.
Select your macro
Select your macro
  • You have created now a toolbar called "Camera" (with the Macro-tool Camera in it)
  • Click the Close button.
Close
Close
  • Your new toolbar is now contained in the toolbars' right-click menu. Its Icons (in our example only the camera) are visible, if the toolbar is activated (blue checkmark).
New Toolbar
New Toolbar