Macro FCInfo ToolBar/pl

Description
Gives information about the selected shape and can display a conversion of radius, diameter, length, area, volume ... in different units (metric and imperial) in a toolBar. The information to be displayed is parametrizable in the Parameter of FreeCAD.



Usage
After run the macro, go to Menu → Tools → Edit parameters ... :BaseApp/Preferences/Macros/FCMmacros/FCInfo_ToolBar

and check the info to display.

The complete info hare displayed in the ToolTip window, the checked option is visible if the " * " is displayed.

Use the button reset after change one option in the parameter window.

The Unit size can be selected : km, hm, dam, m, dm, cm, mm, µm, nm, pm, fm, inch, link, foot, yard, perch, chain, furlong, mile, league, nautique.



Options
The options are located in the Parameter of FreeCAD:

''Menu → Tools → Edit parameters ... :BaseApp/Preferences/Macros/FCMmacros/FCInfo_ToolBar''


 * switch_User_ToolbarIconSize
 * if = : the icon toolBar respect the FreeCAD value for the icon size
 * if = : the icon take the values of the variable seT_User_sizeIconX and seT_User_sizeIconY


 * seT_User_sizeIconX
 * set the value X of the Icon


 * seT_User_sizeIconY
 * set the value Y of the Icon


 * seT_User_setFixed_Tool_Bar_Width
 * set the Width of the ToolBar


 * seT_User_setFixed_Tool_Bar_Height
 * set the Height of the ToolBar


 * switch_User_Work_With_Preselection
 * Work With the Preselectiond, update the data in real time


 * seT_User_StyleSheetColorToolBar
 * set the color of the toolBar in HTML format example : #F8E6E0
 * if the value is 0 the toolBar take the system color


 * seT_User_DecimalValue
 * give the number of decimal of the number (Default 2)


 * seT_User_TextHeigthValue
 * give the text height of the toolBar


 * switch_User_Display_objectName
 * display the object Name


 * switch_User_Display_SubElementName
 * display the SubElementName


 * switch_User_Display_ShapeType
 * display the Shape type (TyS:)


 * switch_User_Display_TypeId
 * display the TypeId (TyI:)


 * switch_User_Display_RadiusObject
 * display the radius and the diameter (r:) [D:]


 * switch_User_Display_LengthObject
 * display the Length of the edge selected or the Perimeter of the face selected
 * (L:) display the Length of the wire, edge, line selected
 * (P:) display the Perimeter if the face is selected


 * switch_User_Display_SommeAllEdgesObject
 * display the somme of the all edge of the object selected (Se:)


 * switch_User_Display_NumberFacesMesh
 * display the number of Faces of the Mesh object (Nf:)


 * switch_User_Display_NumberPointsMeshPoints
 * display the number of points of the Mesh object (Np:)


 * switch_User_Display_NumberEdgesMesh
 * display the number of edges of the Mesh object (Ne:)


 * switch_User_Display_AreaObject
 * display the area of the object (A:)


 * switch_User_Display_AreaSubObject
 * display the area of the face selected (Af:)


 * switch_User_Display_VolumeObject
 * display the volume of the object (V:)


 * switch_User_Display_BsplineObject
 * display the number of node of the Bspline selected
 * (BSpline) display the number of node of the BSpline
 * (BSrA) BSPline radius approximative first radius of the BSpline
 * (BSS) BSPline Points Shape number points of the Bspline (case Shape)
 * (BSc) BSPline Points Sub Object number points of sub object selected (case Edge)


 * switch_User_Display_CentreObject
 * display the center of the circle (if one circle is detected) or of the object selected
 * (Ce:) display the center of circle (if detected), face, edge ... BBoxCenter of face, edge ... Sub selection" + "\n\n")


 * switch_User_Display_CentreBoundBoxObject
 * display the boundingBox center of the object (BBCe:)


 * switch_User_Display_Position
 * display the coordinates point mouse pointed (Pos:)


 * switch_User_NotInfoOnBeginning
 * if it is the info (this information) is displayed
 * if it is the info is not displayed


 * seT_User_UnitSymbolSquare
 * give the symbol square (Default 2)


 * seT_User_UnitSymbolCube
 * give the symbol cube (Default 3)


 * seT_User_UnitSymbolMicro
 * give the symbol micro (Default u)

in command line
In your shortcut verify your right path

"Complete_path_of_FreeCAD" "Complete_path_of_the_macro.FCMacro"

example:

in Mod directory

 * 1) After install the macro with Addon Manager
 * 2) Create the FCInfo_ToolBar directory
 * 3) Copy the macro FCInfo_ToolBar.FCMacro (copy not move) in the FCInfo_ToolBar directory and rename it in FCInfo_ToolBar.py
 * 4) Create a file named InitGui.py
 * 5) Paste the code in InitGui.py:

enjoy
 * 1) save the file
 * 2) run FreeCAD
 * 3) if the macro not run (normal) execute the macro FCInfo_ToolBar.FCMacro as a normal macro
 * 4) the next start of FreeCAD the macro must start automatically

Link
The forum discussion Feature request: coordinates display

Version
version 00.04 28/06/2023 : correction styleSheet and:

replaced by:

version: (00.02 +) 00.03 2022/03/22 : add somme all edges

version: 00.02 2022/03/14 : add calcul in real time (with preselection), dimension of toolBar, add info mesh and points

version: 00.01 2022/02/16 :