Available Parameter Editor variables

Post here for help on using FreeCAD's graphical user interface (GUI).
Forum rules
and Helpful information
IMPORTANT: Please click here and read this first, before asking for help

Also, be nice to others! Read the FreeCAD code of conduct!
Post Reply
937
Posts: 25
Joined: Thu May 13, 2021 10:11 pm

Available Parameter Editor variables

Post by 937 »

Hi,

From https://wiki.freecadweb.org/Property_editor
Not all properties can be modified always; depending on the specific status of the property, some of them will be invisible (not
listed), or be read-only (not editable).
I would like to change the appearance of the read only properties. Is that possible? Also, what are the things I can add here, if this is the right window?
Parameter Editor.png
Parameter Editor.png (26.78 KiB) Viewed 1618 times

Or a different question, @TheMarkster added a bunch of parameters here, where could he have found those?

Edit, answer here: https://forum.freecadweb.org/viewtopic. ... 5&p=255670
7-Parameter Editor.png
7-Parameter Editor.png (26.54 KiB) Viewed 1618 times
Last edited by 937 on Sun Jun 20, 2021 10:59 pm, edited 1 time in total.
TheMarkster
Veteran
Posts: 5505
Joined: Thu Apr 05, 2018 1:53 am

Re: Edit Property Editor parameters

Post by TheMarkster »

It is unlikely you can use the parameter editor to change a property from readonly as that is usually hard coded in the software perhaps when the property is created or this might be toggled according to the mode the software is in. For example if a sketch is not attached then the attachment offset property is likely to be readonly while if the sketch is attached then the placement is likely to be readonly.

As to where to find some parameters some of them are undocumented in the wiki and can only be found by browsing the source code, which can be found on github.
937
Posts: 25
Joined: Thu May 13, 2021 10:11 pm

Re: Edit Property Editor parameters

Post by 937 »

TheMarkster wrote: Sun Jun 20, 2021 5:40 pm It is unlikely you can use the parameter editor to change a property from readonly
Thanks. Also for your tutorials. I don't want to change a property, I only want to change its appearance in the property editor, if that makes a difference.

By searching the files in the source code I found the parameters you changed were in src/Gui/Tree.cpp

One would think the thing I'd like to find is probably in src/Gui/propertyeditor? In PropertyEditor.cpp or PropertyItem.cpp?
937
Posts: 25
Joined: Thu May 13, 2021 10:11 pm

Re: Edit Property Editor parameters

Post by 937 »

I've been scanning the source code. I think if you use the right program you can relatively effortlessly scan through the occurrences of GetUnsigned and GetBool for example and see if there's anything you'd like to change the appearance of:
GetUnsigned.png
GetUnsigned.png (28.83 KiB) Viewed 1568 times
937
Posts: 25
Joined: Thu May 13, 2021 10:11 pm

Re: Edit Property Editor parameters

Post by 937 »

Deleted.
Last edited by 937 on Sun Jun 20, 2021 10:54 pm, edited 1 time in total.
937
Posts: 25
Joined: Thu May 13, 2021 10:11 pm

Re: Edit Property Editor parameters

Post by 937 »

Deleted.
Last edited by 937 on Sun Jun 20, 2021 10:53 pm, edited 1 time in total.
937
Posts: 25
Joined: Thu May 13, 2021 10:11 pm

Re: Edit Property Editor parameters

Post by 937 »

Occurrences of GetUnsigned(", GetBool(", GetFloat(", and GetInt(" in src\Gui

GetString(" didn't seem to give a result.

Code: Select all

[b]\src\Gui\ViewProviderGeometryObject.cpp[/b]
93         unsigned long shcol = hGrp->GetUnsigned("DefaultShapeColor",3435973887UL); // light gray (204,204,204)
250     unsigned long bbcol = hGrp->GetUnsigned("BoundingBoxColor",4294967295UL); // white (255,255,255)

[b]\src\Gui\ViewProviderBuilder.cpp[/b]
75         highlight = hGrp->GetUnsigned("HighlightColor", highlight);
86         selection = hGrp->GetUnsigned("SelectionColor", selection);

[b]\src\Gui\ViewProviderAnnotation.cpp[/b]
74     unsigned long col = hGrp->GetUnsigned("AnnotationTextColor",4294967295UL); // light grey
200     highlight = hGrp->GetUnsigned("HighlightColor", highlight);
206     selection = hGrp->GetUnsigned("SelectionColor", selection);

[b]\src\Gui\View3DInventor.cpp[/b]
254         unsigned long headlight = rGrp.GetUnsigned("HeadlightColor",ULONG_MAX); // default color (white)
279         unsigned long backlight = rGrp.GetUnsigned("BacklightColor",ULONG_MAX); // default color (white)
314         highlight = rGrp.GetUnsigned("HighlightColor", highlight);
324         selection = rGrp.GetUnsigned("SelectionColor", selection);
444         unsigned long col1 = rGrp.GetUnsigned("BackgroundColor",3940932863UL);
445         unsigned long col2 = rGrp.GetUnsigned("BackgroundColor2",859006463UL); // default color (dark blue)
446         unsigned long col3 = rGrp.GetUnsigned("BackgroundColor3",2880160255UL); // default color (blue/grey)
447         unsigned long col4 = rGrp.GetUnsigned("BackgroundColor4",1869583359UL); // default color (blue/grey)

[b]\src\Gui\Tree.cpp[/b]
3100     unsigned long col = hGrp->GetUnsigned("TreeEditColor",4294902015);
4491             unsigned long col = hGrp->GetUnsigned("TreeActiveColor",3873898495);

[b]\src\Gui\SplitView3DInventor.cpp[/b]
128         unsigned long headlight = rGrp.GetUnsigned("HeadlightColor",ULONG_MAX); // default color (white)
157         unsigned long backlight = rGrp.GetUnsigned("BacklightColor",ULONG_MAX); // default color (white)
195         highlight = rGrp.GetUnsigned("HighlightColor", highlight);
206         selection = rGrp.GetUnsigned("SelectionColor", selection);
278         unsigned long col1 = rGrp.GetUnsigned("BackgroundColor",3940932863UL);
279         unsigned long col2 = rGrp.GetUnsigned("BackgroundColor2",859006463UL); // default color (dark blue)
280         unsigned long col3 = rGrp.GetUnsigned("BackgroundColor3",2880160255UL); // default color (blue/grey)
281         unsigned long col4 = rGrp.GetUnsigned("BackgroundColor4",1869583359UL); // default color (blue/grey)

[b]\src\Gui\SoFCUnifiedSelection.cpp[/b]
190         highlight = hGrp->GetUnsigned("HighlightColor", highlight);
202         selection = hGrp->GetUnsigned("SelectionColor", selection);

[b]\src\Gui\SoFCSelection.cpp[/b]
1080         highlight = hGrp->GetUnsigned("HighlightColor", highlight);
1091         selection = hGrp->GetUnsigned("SelectionColor", selection);

[b]\src\Gui\ReportView.cpp[/b]
477         value = getWindowParameter()->GetUnsigned("colorText", value);

[b]\src\Gui\PythonConsole.cpp[/b]
936         value = getWindowParameter()->GetUnsigned("Text", value);



Code: Select all

[b]\src\Gui\Workbench.cpp[/b]
262         bool active = (*it)->GetBool("Active", true);
780     bool enabled = group->GetBool("Enabled", false);

[b]\src\Gui\ViewProviderGeometryObject.cpp[/b]
83     bool randomColor = hGrp->GetBool("RandomColor", false);
111     bool enableSel = hGrp->GetBool("EnableSelection", true);

[b]\src\Gui\ViewProviderBuilder.cpp[/b]
66     bool enablePre = hGrp->GetBool("EnablePreselection", true);
67     bool enableSel = hGrp->GetBool("EnableSelection", true);

[b]\src\Gui\View3DInventor.cpp[/b]
276         _viewer->setBacklight(rGrp.GetBool("EnableBacklight", false));
302         SoFCEnableHighlightAction cAct(rclGrp.GetBool("EnablePreselection", true));
307         SoFCEnableSelectionAction cAct(rclGrp.GetBool("EnableSelection", true));
345         bool on = rGrp.GetBool("ResetCursorPosition",false);
349         bool on = rGrp.GetBool("InvertZoom", true);
353         bool on = rGrp.GetBool("ZoomAtCursor", true);
378         _viewer->setFeedbackVisibility(rGrp.GetBool("CornerCoordSystem",true));
381         _viewer->setAxisCross(rGrp.GetBool("ShowAxisCross",false));
384         _viewer->setAnimationEnabled(rGrp.GetBool("UseAutoRotation",false));
387         _viewer->setGradientBackground((rGrp.GetBool("Gradient",true)));
390         _viewer->setEnabledFPSCounter(rGrp.GetBool("ShowFPS",false));
393         _viewer->setEnabledNaviCube(rGrp.GetBool("ShowNaviCube",true));
399         _viewer->setEnabledVBO(rGrp.GetBool("UseVBO",false));
406         if (rGrp.GetBool("Orthographic", true))
412         if (rGrp.GetBool("DimensionsVisible", true))
418         if (rGrp.GetBool("Dimensions3dVisible", true))
424         if (rGrp.GetBool("DimensionsDeltaVisible", true))
454         if (rGrp.GetBool("UseBackgroundColorMid",false) == false)
1057         if (hGrp->GetBool("SameStyleForAllViews", true))

[b]\src\Gui\Tree.cpp[/b]
4482             bool bold = hGrp->GetBool("TreeActiveBold",true);
4483             bool italic = hGrp->GetBool("TreeActiveItalic",false);
4484             bool underlined = hGrp->GetBool("TreeActiveUnderlined",false);
4485             bool overlined = hGrp->GetBool("TreeActiveOverlined",false);

[b]\src\Gui\Thumbnail.cpp[/b]
106             ("User parameter:BaseApp/Preferences/Document")->GetBool("AddThumbnailLogo",true)) {

[b]\src\Gui\TaskElementColors.cpp[/b]
324     d->ui->recompute->setChecked(hPart->GetBool("ColorRecompute",true));
325     d->ui->onTop->setChecked(hPart->GetBool("ColorOnTop",true));

[b]\src\Gui\SplitView3DInventor.cpp[/b]
154             (*it)->setBacklight(rGrp.GetBool("EnableBacklight", false));
182         SoFCEnableHighlightAction cAct(rGrp.GetBool("EnablePreselection", true));
187         SoFCEnableSelectionAction cAct(rGrp.GetBool("EnableSelection", true));
232         bool on = rGrp.GetBool("ResetCursorPosition",false);
242             (*it)->setFeedbackVisibility(rGrp.GetBool("CornerCoordSystem",true));
246             (*it)->setAnimationEnabled(rGrp.GetBool("UseAutoRotation",false));
250             (*it)->setGradientBackground((rGrp.GetBool("Gradient",true)));
254             (*it)->setEnabledFPSCounter(rGrp.GetBool("ShowFPS",false));
259         //    (*it)->setEnabledVBO(rGrp.GetBool("UseVBO",false));
264         if (rGrp.GetBool("Orthographic", true)) {
289             if (rGrp.GetBool("UseBackgroundColorMid",false) == false)

[b]\src\Gui\SoFCUnifiedSelection.cpp[/b]
181     bool enablePre = hGrp->GetBool("EnablePreselection", true);
182     bool enableSel = hGrp->GetBool("EnableSelection", true);

[b]\src\Gui\SoFCSelection.cpp[/b]
1071     bool enablePre = hGrp->GetBool("EnablePreselection", true);
1072     bool enableSel = hGrp->GetBool("EnableSelection", true);

[b]\src\Gui\ReportView.cpp[/b]
273                 if (group->GetBool("checkShowReportViewOnWarning", true)) {
277                 if (group->GetBool("checkShowReportViewOnError", true)) {
281                 if (group->GetBool("checkShowReportViewOnNormalMessage", false)) {
285                 if (group->GetBool("checkShowReportViewOnLogMessage", false)) {
446         bool showTimecode = getWindowParameter()->GetBool("checkShowReportTimecode", true);
486     bool bShowOnLog = hGrp->GetBool("checkShowReportViewOnLogMessage",false);
487     bool bShowOnNormal = hGrp->GetBool("checkShowReportViewOnNormalMessage",false);
488     bool bShowOnWarn = hGrp->GetBool("checkShowReportViewOnWarning",true);
489     bool bShowOnError = hGrp->GetBool("checkShowReportViewOnError",true);
624     bool show = getWindowParameter()->GetBool("checkShowReportViewOnWarning", true);
630     bool show = getWindowParameter()->GetBool("checkShowReportViewOnError", true);
636     bool show = getWindowParameter()->GetBool("checkShowReportViewOnNormalMessage", false);
642     bool show = getWindowParameter()->GetBool("checkShowReportViewOnLogMessage", false);

[b]\src\Gui\PythonConsole.cpp[/b]
492         GetGroup("BaseApp")->GetGroup("Preferences")->GetGroup("General")->GetBool("PythonWordWrap", true);
825         bool check = hPrefGrp->GetBool("CheckSystemExit",true);
1272     saveh->setChecked(hGrp->GetBool("SavePythonHistory", false));
1293     if (hGrp->GetBool("PythonWordWrap", true)) {
1403     if (!hGrp->GetBool("SavePythonHistory", false))
1428     if (!hGrp->GetBool("SavePythonHistory", false))

[b]\src\Gui\PropertyView.cpp[/b]
95     propertyEditorView->setAutomaticDocumentUpdate(_GetParam()->GetBool("AutoTransactionView", false));
96     propertyEditorView->setAutomaticExpand(_GetParam()->GetBool("AutoExpandView", false));
100     propertyEditorData->setAutomaticDocumentUpdate(_GetParam()->GetBool("AutoTransactionData", true));
101     propertyEditorData->setAutomaticExpand(_GetParam()->GetBool("AutoExpandData", false));

[b]\src\Gui\NavigationStyle.cpp[/b]
237         ("User parameter:BaseApp/Preferences/View")->GetBool("InvertZoom",true);
239         ("User parameter:BaseApp/Preferences/View")->GetBool("ZoomAtCursor",true);

[b]\src\Gui\NaviCube.cpp[/b]
1052
1295

[b]\src\Gui\MenuManager.cpp[/b]
205         ("User parameter:BaseApp/Preferences/MainWindow")->GetBool("ClearMenuBar",false)) {

[b]\src\Gui\MainWindow.cpp[/b]
377         bool enabled = group->GetBool("Enabled", true);
378         if (enabled != group->GetBool("Enabled", false)) {
380                             ->GetGroup("MainWindow")->GetGroup("DockWindows")->GetBool("Std_TreeView",false);
398         bool enabled = group->GetBool("Enabled", true);
399         if (enabled != group->GetBool("Enabled", false)) {
401                             ->GetGroup("MainWindow")->GetGroup("DockWindows")->GetBool("Std_PropertyView",false);
429             enable = group->GetBool("Enabled", true);
455         if (hGrp->GetBool("PythonWordWrap", true)) {
478             enabled = deprecateGroup->GetBool("Enabled", enabled);
483         enabled = group->GetBool("Enabled", enabled);
595         checkBox.setChecked(hGrp->GetBool("ConfirmAll",false));
685     bool saveWB = hGrp->GetBool("SaveWBbyTab", false);
1011     bool saveWB = hGrp->GetBool("SaveWBbyTab", false);
1257     if (hGrp->GetBool("CreateNewDoc", false)) {
1263     if (hGrp->GetBool("RecoveryEnabled", true)) {
1441         if (hGrp->GetBool("ShowSplasher", true)) {

[b]\src\Gui\Macro.cpp[/b]
76     this->recordGui         = this->params->GetBool("RecordGui", true);
77     this->guiAsComment      = this->params->GetBool("GuiAsComment", true);
78     this->scriptToPyConsole = this->params->GetBool("ScriptToPyConsole", true);
79     this->localEnv          = this->params->GetBool("LocalEnvironment", true);
271         PyObject* pyout = hGrp->GetBool("RedirectPythonOutput",true) ? new OutputStdout : 0;
272         PyObject* pyerr = hGrp->GetBool("RedirectPythonErrors",true) ? new OutputStderr : 0;

[b]\src\Gui\GuiApplicationNativeEventAware.cpp[/b]
184     bool  dominant           = group->GetBool("Dominant"); // Is dominant checked
185     bool  flipXY             = group->GetBool("FlipYZ");; // Is Flip X/Y checked
190     enabled[0] = group->GetBool("Translations", true) && group->GetBool("PanLREnable", true);
191     enabled[1] = group->GetBool("Translations", true) && group->GetBool("PanUDEnable", true);
192     enabled[2] = group->GetBool("Translations", true) && group->GetBool("ZoomEnable", true);
193     enabled[3] = group->GetBool("Rotations", true) && group->GetBool("TiltEnable", true);
194     enabled[4] = group->GetBool("Rotations", true) && group->GetBool("RollEnable", true);
195     enabled[5] = group->GetBool("Rotations", true) && group->GetBool("SpinEnable", true);
199     reversed[0] = group->GetBool("PanLRReverse");
200     reversed[1] = group->GetBool("PanUDReverse");
201     reversed[2] = group->GetBool("ZoomReverse");
202     reversed[3] = group->GetBool("TiltReverse");
203     reversed[4] = group->GetBool("RollReverse");
204     reversed[5] = group->GetBool("SpinReverse");
216     if (group->GetBool("Calibrate"))

[b]\src\Gui\GraphvizView.cpp[/b]
100         if(hGrp->GetBool("Unflatten", true)) {
253     bool on = hGrp->GetBool("InvertZoom", true);
430     if(depGrp->GetBool("Unflatten", true)) {

[b]\src\Gui\GestureNavigationStyle.cpp[/b]
685                 ("User parameter:BaseApp/Preferences/View")->GetBool("DisableTouchTilt",true));
839                 ("User parameter:BaseApp/Preferences/View")->GetBool("NavigationDebug");

[b]\src\Gui\FileDialog.cpp[/b]
64     notNativeDialog = group->GetBool("DontUseNativeDialog", notNativeDialog);

[b]\src\Gui\ExpressionCompleter.cpp[/b]
782     return handle->GetBool("CompleterCaseSensitive", false);
789     return handle->GetBool("CompleterMatchExact", false);

[b]\src\Gui\Document.cpp[/b]
224     if (hGrp->GetBool("UsingUndo",true)) {
230     d->_changeViewTouchDocument = hGrp->GetBool("ChangeViewProviderTouchDocument", true);
1315         if (hGrp->GetBool("SaveThumbnail", false)) {

[b]\src\Gui\DlgToolbarsImp.cpp[/b]
262         bool active = (*it)->GetBool("Active", true);

[b]\src\Gui\DlgSettingsSelection.cpp[/b]
61     ui->checkBoxAutoSwitch->setChecked(handle->GetBool("SyncView"));
62     ui->checkBoxAutoExpand->setChecked(handle->GetBool("SyncSelection"));
63     ui->checkBoxPreselect->setChecked(handle->GetBool("PreSelection"));
64     ui->checkBoxRecord->setChecked(handle->GetBool("RecordSelection"));
65     ui->checkBoxSelectionCheckBoxes->setChecked(handle->GetBool("CheckBoxesSelection"));

[b]\src\Gui\DlgSettingsNavigation.cpp[/b]
142     bool showNaviCube = hGrp->GetBool("ShowNaviCube", true);

[b]\src\Gui\DlgPreferencesImp.cpp[/b]
279                               GetBool("SaveUserParameter", true);
392                           GetBool("SaveUserParameter", true);

[b]\src\Gui\DlgMacroExecuteImp.cpp[/b]
437     bool showAgain = App::GetApplication().GetParameterGroupByPath("User parameter:BaseApp/Preferences/Macro")->GetBool("ShowWalkthroughMessage", true);

[b]\src\Gui\DlgGeneralImp.cpp[/b]
123             GetGroup("BaseApp")->GetGroup("Preferences")->GetGroup("General")->GetBool("PythonWordWrap", true);
231     bool propertyView = hGrp->GetGroup("PropertyView")->GetBool("Enabled",false);
232     bool treeView = hGrp->GetGroup("TreeView")->GetBool("Enabled",false);
233     bool comboView = hGrp->GetGroup("ComboView")->GetBool("Enabled",true);
241     ui->tiledBackground->setChecked(hGrp->GetBool("TiledBackground", false));

[b]\src\Gui\DlgExpressionInput.cpp[/b]
81         ("User parameter:BaseApp/Preferences/Expression")->GetBool("NoSystemBackground", false);

[b]\src\Gui\DlgCustomizeSpNavSettings.cpp[/b]
97     ui->CBDominant->setChecked(spaceballMotionGroup()->GetBool("Dominant", false));
98     ui->CBFlipYZ->setChecked(spaceballMotionGroup()->GetBool("FlipYZ", false));
99     ui->CBRotations->setChecked(spaceballMotionGroup()->GetBool("Rotations", true));
100     ui->CBTranslations->setChecked(spaceballMotionGroup()->GetBool("Translations", true));
103     ui->CBEnablePanLR ->setChecked(spaceballMotionGroup()->GetBool("PanLREnable", true));
104     ui->CBReversePanLR->setChecked(spaceballMotionGroup()->GetBool("PanLRReverse", false));
107     ui->CBEnablePanUD ->setChecked(spaceballMotionGroup()->GetBool("PanUDEnable", true));
108     ui->CBReversePanUD->setChecked(spaceballMotionGroup()->GetBool("PanUDReverse", false));
111     ui->CBEnableZoom ->setChecked(spaceballMotionGroup()->GetBool("ZoomEnable", true));
112     ui->CBReverseZoom->setChecked(spaceballMotionGroup()->GetBool("ZoomReverse", false));
115     ui->CBEnableTilt ->setChecked(spaceballMotionGroup()->GetBool("TiltEnable", true));
116     ui->CBReverseTilt->setChecked(spaceballMotionGroup()->GetBool("TiltReverse", false));
119     ui->CBEnableRoll ->setChecked(spaceballMotionGroup()->GetBool("RollEnable", true));
120     ui->CBReverseRoll->setChecked(spaceballMotionGroup()->GetBool("RollReverse", false));
123     ui->CBEnableSpin ->setChecked(spaceballMotionGroup()->GetBool("SpinEnable", true));
124     ui->CBReverseSpin->setChecked(spaceballMotionGroup()->GetBool("SpinReverse", false));

[b]\src\Gui\DlgAddProperty.cpp[/b]
67     ui->chkAppend->setChecked(hGrp->GetBool("NewPropertyAppend",true));

[b]\src\Gui\CommandView.cpp[/b]
3196     bool visibility = group->GetBool("DimensionsVisible", true);

[b]\src\Gui\CommandDoc.cpp[/b]
623     if (hViewGrp->GetBool("ShowAxisCross"))
1489     bool create = hGrp->GetBool("TransactionOnRecompute", false);

[b]\src\Gui\Command.cpp[/b]
1154             macro->systemMacro = (*it)->GetBool("System", false);

[b]\src\Gui\AutoSaver.cpp[/b]
165         bool save = hGrp->GetBool("SaveThumbnail",false);
202                     if (hGrp->GetBool("SaveBinaryBrep", true))

[b]\src\Gui\Application.cpp[/b]
330         if (hViewGrp->GetBool("UseVBO",false)) {
564                     if (hGrp->GetBool("AutoFitToView", true))
645                     if (hGrp->GetBool("AutoFitToView", true)) {
659             bool addToRecent = parameterGroup->GetBool("RecentIncludesImported", true);
716             bool addToRecent = parameterGroup->GetBool("RecentIncludesExported", false);
1811     bool disableDpiScaling = hDPI->GetBool("DisableDpiScaling", false);
1831     bool useSoftwareOpenGL = hOpenGL->GetBool("UseSoftwareOpenGL", false);
1968     bool themePaths = hTheme->GetBool("ThemeSearchPaths",true);
2004     bool showVersion = hGen->GetBool("ShowVersionInTitle",true);
2022     if (!hDocGrp->GetBool("AutoSaveEnabled", true))
2025     AutoSaver::instance()->setCompressed(hDocGrp->GetBool("AutoSaveCompressed", true));
2034     if (hGrp->GetBool("ComboBoxWheelEventFilter", false)) {
2167     app.setStyleSheet(QLatin1String(style.c_str()), hGrp->GetBool("TiledBackground", false));

[b]\src\Gui\Action.cpp[/b]
748         ("User parameter:BaseApp/Preferences/General")->GetBool("SaveUserParameter", true);
901         ("User parameter:BaseApp/Preferences/General")->GetBool("SaveUserParameter", true);


Code: Select all

[b]\src\Gui\ViewProviderOrigin.cpp[/b]
159     return 0.25 * hGrp->GetFloat("NewDocumentCameraScale",100.0);

[b]\src\Gui\ViewProviderGeometryObject.cpp[/b]
258     return hGrp->GetFloat("BoundingBoxFontSize", 10.0);

[b]\src\Gui\View3DPy.cpp[/b]
699             float q0 = static_cast<float>(hGrp->GetFloat("Q0", 0));
700             float q1 = static_cast<float>(hGrp->GetFloat("Q1", 0));
701             float q2 = static_cast<float>(hGrp->GetFloat("Q2", 0));
702             float q3 = static_cast<float>(hGrp->GetFloat("Q3", 1));
711             scale = hGrp->GetFloat("NewDocumentCameraScale",100.0);

[b]\src\Gui\View3DInventor.cpp[/b]
341         float val = rGrp.GetFloat("Sensitivity",2.0f);
357         float val = rGrp.GetFloat("ZoomStep", 0.0f);
375         _viewer->getSoRenderManager()->setStereoOffset(rGrp.GetFloat("EyeDistance",5.0));
430         _viewer->setPickRadius(rGrp.GetFloat("PickRadius", 5.0f));

[b]\src\Gui\SplitView3DInventor.cpp[/b]
227         float val = rGrp.GetFloat("Sensitivity",2.0f);
238             (*it)->getSoRenderManager()->setStereoOffset(rGrp.GetFloat("EyeDistance",5.0));
275             (*it)->setPickRadius(rGrp.GetFloat("PickRadius", 5.0f));

[b]\src\Gui\NavigationStyle.cpp[/b]
241         ("User parameter:BaseApp/Preferences/View")->GetFloat("ZoomStep",0.2f);

[b]\src\Gui\DlgSettingsNavigation.cpp[/b]
160         q0 = hCustom->GetFloat("Q0", q0);
161         q1 = hCustom->GetFloat("Q1", q1);
162         q2 = hCustom->GetFloat("Q2", q2);
163         q3 = hCustom->GetFloat("Q3", q3);

[b]\src\Gui\DAGView\DAGModel.cpp[/b]
201   direction = group->GetFloat("Direction", 1.0);



Code: Select all

[b]\src\Gui\ViewProviderTextDocument.cpp[/b]
60         GetGroup("BaseApp")->GetGroup("Preferences")->GetGroup("Editor")->GetInt("FontSize", font.pointSize()));

[b]\src\Gui\View3DInventorViewer.cpp[/b]
1957         ("User parameter:BaseApp/Preferences/View")->GetInt("AntiAliasing", 0);

[b]\src\Gui\View3DInventorRiftViewer.cpp[/b]
60     this->setGeometry( hGrp->GetInt("RenderWindowPosX",100) ,
61                        hGrp->GetInt("RenderWindowPosY",100) ,
62                        hGrp->GetInt("RenderWindowSizeW",1920) ,
63                        hGrp->GetInt("RenderWindowSizeH",1080)

[b]\src\Gui\View3DInventor.cpp[/b]
272         long value = rGrp.GetInt("HeadlightIntensity", 100);
297         long value = rGrp.GetInt("BacklightIntensity", 100);
337         int style = rGrp.GetInt("OrbitStyle",1);
361         long mode = rGrp.GetInt("RotationMode", 1);
396         _viewer->setNaviCubeCorner(rGrp.GetInt("CornerNaviCube",1));
402         _viewer->setRenderCache(rGrp.GetInt("RenderCache",0));
433         long renderType = rGrp.GetInt("TransparentObjectRenderType", 0);
897         int msecs = hGrp->GetInt("stopAnimatingIfDeactivated", 3000);

[b]\src\Gui\TextEdit.cpp[/b]
428         int fontSize = hPrefGrp->GetInt("FontSize", 15);
430         int fontSize = hPrefGrp->GetInt("FontSize", 10);
451         int tabWidth = hPrefGrp->GetInt("TabSize", 4);

[b]\src\Gui\SplitView3DInventor.cpp[/b]
148         long value = rGrp.GetInt("HeadlightIntensity", 100);
177         long value = rGrp.GetInt("BacklightIntensity", 100);
222         int style = rGrp.GetInt("OrbitStyle",1);

[b]\src\Gui\Selection.cpp[/b]
1126                 ("User parameter:BaseApp/Preferences/View")->GetInt("SelectionStackSize",100);

[b]\src\Gui\ReportView.cpp[/b]
91     int index = hGrp->GetInt("AutoloadTab", 0);
379     messageSize = _prefs->GetInt("LogMessageSize",0);
381     messageSize = _prefs->GetInt("LogMessageSize",2048);
716         int fontSize = rclGrp.GetInt("FontSize", 10);

[b]\src\Gui\PythonConsole.cpp[/b]
501         int fontSize = hPrefGrp->GetInt("FontSize", 10);

[b]\src\Gui\PropertyView.cpp[/b]
104     int preferredTab = _GetParam()->GetInt("LastTabIndex", 1);

[b]\src\Gui\Placement.cpp[/b]
130     long index = hGrp->GetInt("RotationMethod");

[b]\src\Gui\NavigationStyle.cpp[/b]
243         ("User parameter:BaseApp/Preferences/View")->GetInt("RotationMode", 1);

[b]\src\Gui\NaviCube.cpp[/b]
432    sansFont.setWeight(hGrp->GetInt("FontWeight", 87));
433    sansFont.setStretch(hGrp->GetInt("FontStretch", 62));
439    if (hGrp->GetInt("FontWeight") > 0) {
440    sansFont.setWeight(hGrp->GetInt("FontWeight"));
442    if (hGrp->GetInt("FontStretch") > 0) {
443    sansFont.setStretch(hGrp->GetInt("FontStretch"));
925    int m_CubeWidgetOffsetX = hGrp->GetInt("OffsetX", 0);
926    int m_CubeWidgetOffsetY = hGrp->GetInt("OffsetY", 0);
1292    long step = Base::clamp(hGrp->GetInt("NaviStepByTurn", 8), 4L, 36L);

[b]\src\Gui\GuiApplicationNativeEventAware.cpp[/b]
161     long remap = group->GetInt("Remapping", 12345);
186     float generalSensitivity = convertPrefToSensitivity(group->GetInt("GlobalSensitivity"));
209     sensitivity[0] = convertPrefToSensitivity(group->GetInt("PanLRSensitivity"));
210     sensitivity[1] = convertPrefToSensitivity(group->GetInt("PanUDSensitivity"));
211     sensitivity[2] = convertPrefToSensitivity(group->GetInt("ZoomSensitivity"));
212     sensitivity[3] = convertPrefToSensitivity(group->GetInt("TiltSensitivity"));
213     sensitivity[4] = convertPrefToSensitivity(group->GetInt("RollSensitivity"));
214     sensitivity[5] = convertPrefToSensitivity(group->GetInt("SpinSensitivity"));
231         motionDataArray[0] = motionDataArray[0] - group->GetInt("CalibrationX");
232         motionDataArray[1] = motionDataArray[1] - group->GetInt("CalibrationY");
233         motionDataArray[2] = motionDataArray[2] - group->GetInt("CalibrationZ");
234         motionDataArray[3] = motionDataArray[3] - group->GetInt("CalibrationXr");
235         motionDataArray[4] = motionDataArray[4] - group->GetInt("CalibrationYr");
236         motionDataArray[5] = motionDataArray[5] - group->GetInt("CalibrationZr");

[b]\src\Gui\GestureNavigationStyle.cpp[/b]
360                     ("User parameter:BaseApp/Preferences/View")->GetInt("GestureMoveThreshold", ns.mouseMoveThreshold);
364             ("User parameter:BaseApp/Preferences/View")->GetInt("GestureTapHoldTimeout", this->hold_timeout);

[b]\src\Gui\Document.cpp[/b]
227         d->_pcDocument->setMaxUndoStackSize(hGrp->GetInt("MaxUndoSize",20));
1316             int size = hGrp->GetInt("ThumbnailSize", 128);

[b]\src\Gui\DlgSettingsUnitsImp.cpp[/b]
153     ui->comboBox_ViewSystem->setCurrentIndex(hGrp->GetInt("UserSchema",0));
154     ui->spinBoxDecimals->setValue(hGrp->GetInt("Decimals",Base::UnitsApi::getDecimals()));
157     FracInch = hGrp->GetInt("FracInch", Base::QuantityFormat::getDefaultDenominator());

[b]\src\Gui\DlgSettingsNavigation.cpp[/b]
132     index = hGrp->GetInt("OrbitStyle", int(NavigationStyle::Trackball));
136     index = hGrp->GetInt("CornerNaviCube", 1);
139     index = hGrp->GetInt("RotationMode", 1);

[b]\src\Gui\DlgSettingsMacroImp.cpp[/b]
71         recent->resizeList(hGrp->GetInt("RecentMacros", 4));

[b]\src\Gui\DlgSettings3DViewImp.cpp[/b]
125     int index = hGrp->GetInt("AntiAliasing", int(Gui::View3DInventorViewer::None));
132     index = hGrp->GetInt("RenderCache", 0);
137     int const current = hGrp->GetInt("MarkerSize", 9L);

[b]\src\Gui\DlgGeneralImp.cpp[/b]
103         recent->resizeList(hGrp->GetInt("RecentFiles", 4));

[b]\src\Gui\DlgEditorImp.cpp[/b]
229     ui->fontSize->setValue( hGrp->GetInt("FontSize", ui->fontSize->value()) );

[b]\src\Gui\DlgCustomizeSpNavSettings.cpp[/b]
101     ui->SliderGlobal->setValue(spaceballMotionGroup()->GetInt("GlobalSensitivity", 0));
105     ui->SliderPanLR   ->setValue(spaceballMotionGroup()->GetInt("PanLRSensitivity", 0));
109     ui->SliderPanUD   ->setValue(spaceballMotionGroup()->GetInt("PanUDSensitivity", 0));
113     ui->SliderZoom   ->setValue(spaceballMotionGroup()->GetInt("ZoomSensitivity", 0));
117     ui->SliderTilt   ->setValue(spaceballMotionGroup()->GetInt("TiltSensitivity", 0));
121     ui->SliderRoll   ->setValue(spaceballMotionGroup()->GetInt("RollSensitivity", 0));
125     ui->SliderSpin   ->setValue(spaceballMotionGroup()->GetInt("SpinSensitivity", 0));

[b]\src\Gui\DAGView\DAGModel.cpp[/b]
121     selectionMode = static_cast<SelectionMode>(group->GetInt("SelectionMode", 0));
191   int fontPointSize = group->GetInt("FontPointSize", 0);

[b]\src\Gui\CommandView.cpp[/b]
1853         int backtype = hExt->GetInt("OffscreenImageBackground",0);

[b]\src\Gui\Application.cpp[/b]
2021     int timeout = hDocGrp->GetInt("AutoSaveTimeout", 15); // 15 min
2029     int size = hGrp->GetInt("ToolbarIconSize", 0);

[b]\src\Gui\Action.cpp[/b]
839     this->visibleItems = hGrp->GetInt("RecentFiles", this->visibleItems);
855     int count = hGrp->GetInt("RecentFiles", this->visibleItems); // save number of files
917     this->shortcut_count = std::min<int>(hGrp->GetInt("ShortcutCount",3),9);//max = 9, e.g. Ctrl+Shift+9
918     this->visibleItems = hGrp->GetInt("RecentMacros",12);
1023         this->visibleItems = hGrp->GetInt("RecentMacros", this->visibleItems);
1024         this->shortcut_count = hGrp->GetInt("ShortcutCount", 3); // number of shortcuts
1043     int count = hGrp->GetInt("RecentMacros", this->visibleItems); // save number of files



TheMarkster
Veteran
Posts: 5505
Joined: Thu Apr 05, 2018 1:53 am

Re: Edit Property Editor parameters

Post by TheMarkster »

937 wrote: Sun Jun 20, 2021 6:40 pm
Thanks. Also for your tutorials. I don't want to change a property, I only want to change its appearance in the property editor, if that makes a difference.

By searching the files in the source code I found the parameters you changed were in src/Gui/Tree.cpp

One would think the thing I'd like to find is probably in src/Gui/propertyeditor? In PropertyEditor.cpp or PropertyItem.cpp?
I see. I was thinking you wanted to make something that is readonly editable so you could change the value. I'm not much on aesthetics, and so haven't played around with themes, but that could be something to look at possibly. Perhaps if you explain what you are exactly trying to do someone will know of a way to do it or perhaps it could be a feature request (typically posted in open discussions).
937
Posts: 25
Joined: Thu May 13, 2021 10:11 pm

Re: Available Parameter Editor variables

Post by 937 »

Maybe a moderator could move the topic then.

I've looked through the variables and something that changed the appearance of the ReadOnly items in the Property Editor (so I don't need to click on them to find out if they are or not) didn't jump out at me yet.

I did find this:
wmayer wrote: Mon Feb 08, 2021 6:29 pm Mit der obigen Änderung kann man über das Kontextmenü im Eigenschaften-Editor die Option aktivieren. Die Änderung geht aber beim Beenden von FreeCAD wieder verloren. Um sie dauerhaft zu setzen, muss man im Parameter-Editor die Schlüssel AutoExpandView und AutoExpandData unter BaseApp/Preferences/PropertyView/ erstellen und auf True setzen.

Das geht dann ab Version 0.19.23992
54-FreeCAD 0.20.png
54-FreeCAD 0.20.png (4.2 KiB) Viewed 1427 times
So to have this checkbox persist add the booleans AutoExpandView and AutoExpandData to BaseApp/Preferences/PropertyView/
I was always checking this so I'm glad for that change.
Post Reply