diff --git a/src/Mod/Start/Gui/AppStartGui.cpp b/src/Mod/Start/Gui/AppStartGui.cpp index 572c764f32..b1ceecf039 100644 --- a/src/Mod/Start/Gui/AppStartGui.cpp +++ b/src/Mod/Start/Gui/AppStartGui.cpp @@ -101,7 +101,8 @@ PyMOD_INIT_FUNC(StartGui) // clang-format off // register preferences pages - new Gui::PrefPageProducer(QT_TRANSLATE_NOOP("QObject", "Start")); + new Gui::PrefPageProducer (QT_TRANSLATE_NOOP("QObject", "Start")); + new Gui::PrefPageProducer (QT_TRANSLATE_NOOP("QObject", "Start")); // clang-format on // instantiating the commands diff --git a/src/Mod/Start/Gui/CMakeLists.txt b/src/Mod/Start/Gui/CMakeLists.txt index fc1c86391b..7140934b15 100644 --- a/src/Mod/Start/Gui/CMakeLists.txt +++ b/src/Mod/Start/Gui/CMakeLists.txt @@ -14,6 +14,7 @@ set(StartGui_LIBS set(StartGui_UIC_SRCS DlgStartPreferences.ui + DlgStartPreferencesAdvanced.ui ) set (Start_TR_QRC ${CMAKE_CURRENT_BINARY_DIR}/Resources/Start_translation.qrc) @@ -26,6 +27,7 @@ SET(StartGui_SRCS ${Start_QRC_SRCS} ${StartGui_UIC_SRCS} DlgStartPreferences.ui + DlgStartPreferencesAdvanced.ui DlgStartPreferencesImp.cpp DlgStartPreferencesImp.h AppStartGui.cpp diff --git a/src/Mod/Start/Gui/DlgStartPreferences.ui b/src/Mod/Start/Gui/DlgStartPreferences.ui index a88215a6db..fbec5bc186 100644 --- a/src/Mod/Start/Gui/DlgStartPreferences.ui +++ b/src/Mod/Start/Gui/DlgStartPreferences.ui @@ -11,22 +11,75 @@ - Start page options + General - + - Start page template + Options - - - + + + + + Switch workbench after loading + + + + + - An optional HTML template that will be used instead of the default start page. + Choose which workbench to switch to after the program launches + + + + + + + Close start page after loading + + + + + + + If checked, will automatically close the Start page when FreeCAD launches + + + Qt::RightToLeft + + + - Template + closeStart + + + Mod/Start + + + + + + + Close and switch on opening file + + + + + + + If application is started by opening a file, apply the two settings above + + + Qt::RightToLeft + + + + + + DoNotShowOnOpen Mod/Start @@ -42,202 +95,6 @@ Contents - - - - Show tips - - - - - - - Show additional folder - - - - - - - If you want the examples to show on the first page - - - Qt::RightToLeft - - - - - - true - - - ShowExamples - - - Mod/Start - - - - - - - If this is checked, the latest posts from the FreeCAD forum will be displayed on the Activity tab - - - Qt::RightToLeft - - - - - - ShowForum - - - Mod/Start - - - - - - - Qt::RightToLeft - - - - - - true - - - ShowFileThumbnailIcons - - - Mod/Start - - - - - - - Shows a notepad next to the file thumbnails, where you can keep notes across sessions - - - Qt::RightToLeft - - - - - - ShowNotes - - - Mod/Start - - - - - - - Show scrollbars - - - - - - - Show notepad - - - - - - - Show forum - - - - - - - An optional custom folder to be displayed at the bottom of the first page. -By using ";;" to separate paths, you can add several folders here - - - ShowCustomFolder - - - Mod/Start - - - - - - - Qt::RightToLeft - - - - - - true - - - ShowScrollBars - - - Mod/Start - - - - - - - Show file thumbnails - - - - - - - Show examples folder contents - - - - - - - Displays help tips in the Start workbench Documents tab - - - Qt::RightToLeft - - - - - - true - - - ShowTips - - - Mod/Start - - - - - - - - 0 - 0 - - - - File thumbnail size - - - @@ -268,7 +125,7 @@ By using ";;" to separate paths, you can add several folders hereQt::LeftToRight - Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter + Qt::AlignLeading|Qt::AlignLeft|Qt::AlignVCenter px @@ -292,6 +149,176 @@ By using ";;" to separate paths, you can add several folders here + + + + Qt::RightToLeft + + + + + + true + + + ShowFileThumbnailIcons + + + Mod/Start + + + + + + + If you want the examples to show on the first page + + + Qt::RightToLeft + + + + + + true + + + ShowExamples + + + Mod/Start + + + + + + + Displays help tips in the Start workbench Documents tab + + + Qt::RightToLeft + + + + + + true + + + ShowTips + + + Mod/Start + + + + + + + Show tips + + + + + + + Show forum + + + + + + + Show notepad + + + + + + + If this is checked, the latest posts from the FreeCAD forum will be displayed on the Activity tab + + + Qt::RightToLeft + + + + + + ShowForum + + + Mod/Start + + + + + + + + 0 + 0 + + + + File thumbnail size + + + + + + + Show examples folder contents + + + + + + + Shows a notepad next to the file thumbnails, where you can keep notes across sessions + + + Qt::RightToLeft + + + + + + ShowNotes + + + Mod/Start + + + + + + + Show file thumbnails + + + + + + + An optional custom folder to be displayed at the bottom of the first page. +By using ";;" to separate paths, you can add several folders here + + + ShowCustomFolder + + + Mod/Start + + + + + + + Show additional folder + + + @@ -301,232 +328,8 @@ By using ";;" to separate paths, you can add several folders hereFonts and colors - - - - Use FreeCAD style sheet - - - - - - - If this is checked and a style sheet is specified in General preferences, it will be used and override the colors below - - - Qt::RightToLeft - - - - - - UseStyleSheet - - - Mod/Start - - - - - - - Background color - - - - - - - - 60 - 60 - - - - The background color behind the panels - - - - 79 - 88 - 116 - - - - BackgroundColor1 - - - Mod/Start - - - - - - - false - - - Background color down gradient - - - - - - - false - - - - 60 - 60 - - - - The down gradient for the background color (currently unsupported) - - - - 127 - 158 - 181 - - - - BackgroundColor2 - - - Mod/Start - - - - - - - Background image - - - - - - - An optional image to display as background - - - BackgroundImage - - - Mod/Start - - - - - - - Background text color - - - - - - - - 60 - 60 - - - - The color of the version text - - - - 95 - 95 - 95 - - - - BackgroundTextColor - - - Mod/Start - - - - - - - Page background color - - - - - - - - 60 - 60 - - - - The background of the main start page area - - - - 255 - 255 - 255 - - - - PageColor - - - Mod/Start - - - - - - - Page text color - - - - - - - - 60 - 60 - - - - The color of the text on the main pages - - - - 0 - 0 - 0 - - - - PageTextColor - - - Mod/Start - - - - - - - Box background color - - - - - + + 60 @@ -551,15 +354,22 @@ By using ";;" to separate paths, you can add several folders here - - + + - Link color + Page text color - - + + + + Page background color + + + + + 60 @@ -567,83 +377,24 @@ By using ";;" to separate paths, you can add several folders here - The color of the links + The background of the main start page area - 0 - 0 + 255 + 255 255 - LinkColor + PageColor Mod/Start - - - - Font family - - - - - - - - - The font family to use on the start page. Can be a font name or a comma-separated series of fallback fonts - - - - - - Arial,Helvetica,sans - - - FontFamily - - - Mod/Start - - - - - - - The base font size to use for all texts of the Start page - - - px - - - 13 - - - FontSize - - - Mod/Start - - - - - - - - - false - - - Open links - - - - + @@ -682,66 +433,195 @@ By using ";;" to separate paths, you can add several folders here - - - - - - - Options - - - - + + - Switch workbench after loading + Font family - - + + + + false + + + Open links + + + + + + + + 60 + 60 + + - Choose which workbench to switch to after the program launches + The background color behind the panels - - - - - - Close start page after loading - - - - - - - If checked, will automatically close the Start page when FreeCAD launches - - - Qt::RightToLeft - - - + + + 79 + 88 + 116 + - closeStart + BackgroundColor1 Mod/Start + + + + Use FreeCAD style sheet + + + + + + + false + + + Background color down gradient + + + + + + + false + + + + 60 + 60 + + + + The down gradient for the background color (currently unsupported) + + + + 127 + 158 + 181 + + + + BackgroundColor2 + + + Mod/Start + + + + + + + Box background color + + + - + - Close and switch on opening file + Background color - - + + + + Background text color + + + + + + + + + The font family to use on the start page. Can be a font name or a comma-separated series of fallback fonts + + + + + + Arial,Helvetica,sans + + + FontFamily + + + Mod/Start + + + + + + + The base font size to use for all texts of the Start page + + + px + + + 13 + + + FontSize + + + Mod/Start + + + + + + + + + + 60 + 60 + + - If application is started by opening a file, apply the two settings above + The color of the links + + + + 0 + 0 + 255 + + + + LinkColor + + + Mod/Start + + + + + + + Link color + + + + + + + If this is checked and a style sheet is specified in General preferences, it will be used and override the colors below Qt::RightToLeft @@ -750,13 +630,85 @@ By using ";;" to separate paths, you can add several folders here - DoNotShowOnOpen + UseStyleSheet Mod/Start + + + + + 60 + 60 + + + + The color of the version text + + + + 95 + 95 + 95 + + + + BackgroundTextColor + + + Mod/Start + + + + + + + + 60 + 60 + + + + The color of the text on the main pages + + + + 0 + 0 + 0 + + + + PageTextColor + + + Mod/Start + + + + + + + An optional image to display as background + + + BackgroundImage + + + Mod/Start + + + + + + + Background image + + + diff --git a/src/Mod/Start/Gui/DlgStartPreferencesAdvanced.ui b/src/Mod/Start/Gui/DlgStartPreferencesAdvanced.ui new file mode 100644 index 0000000000..d97177501e --- /dev/null +++ b/src/Mod/Start/Gui/DlgStartPreferencesAdvanced.ui @@ -0,0 +1,90 @@ + + + DlgStartPreferencesAdvanced + + + + 0 + 0 + 548 + 896 + + + + Advanced + + + + + + Custom HTML Template + + + + + + An optional HTML template that will be used instead of the default start page. + + + Template + + + Mod/Start + + + + + + + + + + Custom CSS + + + + + + <html><head/><body><p>You can paste your custom CSS here and the Start Page will apply it for you. To learn more about how you can style the Start Page, take a look at the HTML and CSS sources:</p><p><a href="https://github.com/FreeCAD/FreeCAD/blob/master/src/Mod/Start/StartPage/StartPage.html"><span style=" text-decoration: underline; color:#1d99f3;">https://github.com/FreeCAD/FreeCAD/blob/master/src/Mod/Start/StartPage/StartPage.html</span></a></p><p><a href="https://github.com/FreeCAD/FreeCAD/blob/master/src/Mod/Start/StartPage/StartPage.css"><span style=" text-decoration: underline; color:#1d99f3;">https://github.com/FreeCAD/FreeCAD/blob/master/src/Mod/Start/StartPage/StartPage.css</span></a></p></body></html> + + + true + + + true + + + + + + + false + + + CustomCSS + + + Mod/Start + + + + + + + + + + + Gui::PrefFileChooser + QWidget +
Gui/PrefWidgets.h
+
+ + Gui::PrefTextEdit + QWidget +
Gui/PrefWidgets.h
+
+
+ + +
diff --git a/src/Mod/Start/Gui/DlgStartPreferencesImp.cpp b/src/Mod/Start/Gui/DlgStartPreferencesImp.cpp index 34f4553c07..4a625ecf91 100644 --- a/src/Mod/Start/Gui/DlgStartPreferencesImp.cpp +++ b/src/Mod/Start/Gui/DlgStartPreferencesImp.cpp @@ -26,6 +26,7 @@ #include "DlgStartPreferencesImp.h" #include "ui_DlgStartPreferences.h" +#include "ui_DlgStartPreferencesAdvanced.h" using namespace StartGui; @@ -90,28 +91,26 @@ void DlgStartPreferencesImp::saveSettings() App::GetApplication() .GetParameterGroupByPath("User parameter:BaseApp/Preferences/Mod/Start") ->SetASCII("AutoloadModule", startWbName.toLatin1()); - ui->colorButton_1->onSave(); - ui->colorButton_2->onSave(); - ui->colorButton_3->onSave(); - ui->colorButton_4->onSave(); - ui->colorButton_5->onSave(); - ui->colorButton_6->onSave(); + ui->backgroundColorButton->onSave(); + ui->backgroundTextColorButton->onSave(); + ui->pageBackgroundColorButton->onSave(); + ui->pageTextColorButton->onSave(); + ui->boxBackgroundColorButton->onSave(); + ui->linkColorButton->onSave(); ui->colorButton_7->onSave(); - ui->fileChooser_1->onSave(); - ui->fileChooser_2->onSave(); - ui->fileChooser_3->onSave(); + ui->backgroundImageFileChooser->onSave(); + ui->showAdditionalFolderFileChooser->onSave(); ui->radioButton_1->onSave(); ui->radioButton_2->onSave(); - ui->checkBox->onSave(); - ui->checkBox_1->onSave(); - ui->checkBox_2->onSave(); - ui->checkBox_3->onSave(); - ui->checkBox_4->onSave(); - ui->checkBox_5->onSave(); - ui->checkBox_6->onSave(); - ui->checkBox_7->onSave(); - ui->lineEdit->onSave(); - ui->spinBox->onSave(); + ui->showNotepadCheckBox->onSave(); + ui->showExamplesCheckBox->onSave(); + ui->closeStartCheckBox->onSave(); + ui->closeAndSwitchCheckBox->onSave(); + ui->showForumCheckBox->onSave(); + ui->useStyleSheetCheckBox->onSave(); + ui->showTipsCheckBox->onSave(); + ui->fontLineEdit->onSave(); + ui->fontSizeSpinBox->onSave(); ui->showFileThumbnailIconsCheckBox->onSave(); ui->fileThumbnailIconSizeSpinBox->onSave(); } @@ -124,28 +123,26 @@ void DlgStartPreferencesImp::loadSettings() ->GetASCII("AutoloadModule", start.c_str()); QString startWbName = QLatin1String(start.c_str()); ui->AutoloadModuleCombo->setCurrentIndex(ui->AutoloadModuleCombo->findData(startWbName)); - ui->colorButton_1->onRestore(); - ui->colorButton_2->onRestore(); - ui->colorButton_3->onRestore(); - ui->colorButton_4->onRestore(); - ui->colorButton_5->onRestore(); - ui->colorButton_6->onRestore(); + ui->backgroundColorButton->onRestore(); + ui->backgroundTextColorButton->onRestore(); + ui->pageBackgroundColorButton->onRestore(); + ui->pageTextColorButton->onRestore(); + ui->boxBackgroundColorButton->onRestore(); + ui->linkColorButton->onRestore(); ui->colorButton_7->onRestore(); - ui->fileChooser_1->onRestore(); - ui->fileChooser_2->onRestore(); - ui->fileChooser_3->onRestore(); + ui->backgroundImageFileChooser->onRestore(); + ui->showAdditionalFolderFileChooser->onRestore(); ui->radioButton_1->onRestore(); ui->radioButton_2->onRestore(); - ui->checkBox->onRestore(); - ui->checkBox_1->onRestore(); - ui->checkBox_2->onRestore(); - ui->checkBox_3->onRestore(); - ui->checkBox_4->onRestore(); - ui->checkBox_5->onRestore(); - ui->checkBox_6->onRestore(); - ui->checkBox_7->onRestore(); - ui->lineEdit->onRestore(); - ui->spinBox->onRestore(); + ui->showNotepadCheckBox->onRestore(); + ui->showExamplesCheckBox->onRestore(); + ui->closeStartCheckBox->onRestore(); + ui->closeAndSwitchCheckBox->onRestore(); + ui->showForumCheckBox->onRestore(); + ui->useStyleSheetCheckBox->onRestore(); + ui->showTipsCheckBox->onRestore(); + ui->fontLineEdit->onRestore(); + ui->fontSizeSpinBox->onRestore(); ui->showFileThumbnailIconsCheckBox->onRestore(); ui->fileThumbnailIconSizeSpinBox->onRestore(); } @@ -163,4 +160,45 @@ void DlgStartPreferencesImp::changeEvent(QEvent* ev) } } + +/** + * Constructs a DlgStartPreferencesAdvancedImp which is a child of 'parent' + */ +DlgStartPreferencesAdvancedImp::DlgStartPreferencesAdvancedImp(QWidget* parent) + : PreferencePage(parent) + , ui(new Ui_DlgStartPreferencesAdvanced) +{ + ui->setupUi(this); +} + +/** + * Destroys the object and frees any allocated resources + */ +DlgStartPreferencesAdvancedImp::~DlgStartPreferencesAdvancedImp() = default; + +void DlgStartPreferencesAdvancedImp::saveSettings() +{ + ui->templateFileChooser->onSave(); + ui->customCSSTextEdit->onSave(); +} + +void DlgStartPreferencesAdvancedImp::loadSettings() +{ + ui->templateFileChooser->onRestore(); + ui->customCSSTextEdit->onRestore(); +} + +/** + * Sets the strings of the subwidgets using the current language. + */ +void DlgStartPreferencesAdvancedImp::changeEvent(QEvent* ev) +{ + if (ev->type() == QEvent::LanguageChange) { + ui->retranslateUi(this); + } + else { + Gui::Dialog::PreferencePage::changeEvent(ev); + } +} + #include "moc_DlgStartPreferencesImp.cpp" diff --git a/src/Mod/Start/Gui/DlgStartPreferencesImp.h b/src/Mod/Start/Gui/DlgStartPreferencesImp.h index 1be74661fe..83cfeade92 100644 --- a/src/Mod/Start/Gui/DlgStartPreferencesImp.h +++ b/src/Mod/Start/Gui/DlgStartPreferencesImp.h @@ -28,6 +28,7 @@ class Ui_DlgStartPreferences; +class Ui_DlgStartPreferencesAdvanced; namespace StartGui { class DlgStartPreferencesImp: public Gui::Dialog::PreferencePage @@ -47,6 +48,23 @@ private: std::unique_ptr ui; }; +class DlgStartPreferencesAdvancedImp: public Gui::Dialog::PreferencePage +{ + Q_OBJECT + +public: + explicit DlgStartPreferencesAdvancedImp(QWidget* parent = nullptr); + ~DlgStartPreferencesAdvancedImp() override; + +protected: + void saveSettings() override; + void loadSettings() override; + void changeEvent(QEvent* e) override; + +private: + std::unique_ptr ui; +}; + }// namespace StartGui #endif// STARTGUI_DLGSTARTPREFERENCESIMP_H diff --git a/src/Mod/Start/StartPage/CMakeLists.txt b/src/Mod/Start/StartPage/CMakeLists.txt index 969b66b260..5d363bb972 100644 --- a/src/Mod/Start/StartPage/CMakeLists.txt +++ b/src/Mod/Start/StartPage/CMakeLists.txt @@ -27,7 +27,7 @@ SET(StartPage_ImageResources images/new_file_thumbnail.svg images/icon_settings.png images/new_empty_file.png - images/new_import_file.png + images/new_open_file.png images/new_parametric_part.png images/new_csg_part.png images/new_2d_draft.png diff --git a/src/Mod/Start/StartPage/LoadNew.py b/src/Mod/Start/StartPage/LoadNew.py index c31f76abef..71b6063c9c 100644 --- a/src/Mod/Start/StartPage/LoadNew.py +++ b/src/Mod/Start/StartPage/LoadNew.py @@ -29,10 +29,12 @@ template_name = str(template) if template_name == "empty_file": FreeCADGui.runCommand("Std_New") StartPage.postStart() -elif template_name == "import_file": - FreeCADGui.runCommand("Std_New") - StartPage.postStart() - FreeCADGui.runCommand("Std_Import") +elif template_name == "open_file": + previous_doc = FreeCADGui.ActiveDocument + FreeCADGui.runCommand("Std_Open") + # workaround to not run postStart() if user cancels the Open dialog + if FreeCADGui.ActiveDocument != previous_doc: + StartPage.postStart() elif template_name == "parametric_part": FreeCADGui.runCommand("Std_New") FreeCADGui.activateWorkbench("PartDesignWorkbench") diff --git a/src/Mod/Start/StartPage/StartPage.css b/src/Mod/Start/StartPage/StartPage.css index 34b8695771..6691267d30 100644 --- a/src/Mod/Start/StartPage/StartPage.css +++ b/src/Mod/Start/StartPage/StartPage.css @@ -24,7 +24,6 @@ body { overflow: hidden; } -OVERFLOW a, a:link, a:visited { @@ -44,6 +43,10 @@ h2 { padding-top: 5px; } +img, a { + -webkit-user-drag: none; +} + .hidden { display: none !important; } @@ -73,7 +76,7 @@ h2 { display: flex; align-items: center; color: TEXTCOLOR; - font-size: 1.3em; + font-size: 1.4em; margin-left: 25px; font-weight: bold; } @@ -113,7 +116,7 @@ ul.tabs { position: absolute; top: 2em; left: 50%; - transform: translateX(-50%); + transform: translateX(calc(-50% - 1em)); } ul.tabs li { @@ -130,7 +133,6 @@ ul.tabs li a { text-decoration: none; outline: 0; font-size: 1.3em; - transition: 100ms; } ul.tabs li a img { @@ -186,6 +188,7 @@ ul.icons { width: 130px; height: THUMBCARDSIZE; background: BOXCOLOR; + border: solid 2px BOXCOLOR; border-radius: 8px; margin: 10px; word-wrap: break-word; @@ -233,6 +236,7 @@ a .caption:visited { width: 18em; height: 5em; background: BOXCOLOR; + border: solid 2px BOXCOLOR; border-radius: 8px; margin: 10px; word-wrap: break-word; diff --git a/src/Mod/Start/StartPage/StartPage.html b/src/Mod/Start/StartPage/StartPage.html index febbc2d379..d48f062fa6 100644 --- a/src/Mod/Start/StartPage/StartPage.html +++ b/src/Mod/Start/StartPage/StartPage.html @@ -6,7 +6,8 @@ @@ -34,7 +35,7 @@
  • - + blog T_BLOG diff --git a/src/Mod/Start/StartPage/StartPage.py b/src/Mod/Start/StartPage/StartPage.py index a953675d29..4951d960bf 100644 --- a/src/Mod/Start/StartPage/StartPage.py +++ b/src/Mod/Start/StartPage/StartPage.py @@ -266,9 +266,9 @@ def build_new_file_card(template): TranslationTexts.T_TEMPLATE_EMPTYFILE_NAME, TranslationTexts.T_TEMPLATE_EMPTYFILE_DESC, ], - "import_file": [ - TranslationTexts.T_TEMPLATE_IMPORTFILE_NAME, - TranslationTexts.T_TEMPLATE_IMPORTFILE_DESC, + "open_file": [ + TranslationTexts.T_TEMPLATE_OPENFILE_NAME, + TranslationTexts.T_TEMPLATE_OPENFILE_DESC, ], "parametric_part": [ TranslationTexts.T_TEMPLATE_PARAMETRICPART_NAME, @@ -286,7 +286,7 @@ def build_new_file_card(template): } if template not in templates: - return + return "" image = "file:///" + os.path.join( os.path.join(FreeCAD.getResourceDir(), "Mod", "Start", "StartPage"), @@ -378,7 +378,13 @@ def handle(): with open(css_filename, "r") as f: CSS = f.read() HTML = HTML.replace("JS", JS) - HTML = HTML.replace("CSS", CSS) + HTML = HTML.replace("DEFAULT_CSS", CSS) + HTML = HTML.replace( + "CUSTOM_CSS", + FreeCAD.ParamGet("User parameter:BaseApp/Preferences/Mod/Start") + .GetString("CustomCSS", "") + .replace("\n", ""), + ) # set the language @@ -496,7 +502,7 @@ def handle(): SECTION_NEW_FILE = "

    " + TranslationTexts.T_NEWFILE + "

    " SECTION_NEW_FILE += "
      " SECTION_NEW_FILE += build_new_file_card("empty_file") - SECTION_NEW_FILE += build_new_file_card("import_file") + SECTION_NEW_FILE += build_new_file_card("open_file") SECTION_NEW_FILE += build_new_file_card("parametric_part") # SECTION_NEW_FILE += build_new_file_card("csg_part") SECTION_NEW_FILE += build_new_file_card("2d_draft") @@ -731,9 +737,6 @@ def handle(): BOXCOLOR = gethexcolor(p.GetUnsigned("BoxColor", 3722305023)) TEXTCOLOR = gethexcolor(p.GetUnsigned("PageTextColor", 255)) BGTCOLOR = gethexcolor(p.GetUnsigned("BackgroundTextColor", 1600086015)) - OVERFLOW = ( - "" if p.GetBool("ShowScrollBars", True) else "body::-webkit-scrollbar {display: none;}" - ) SHADOW = "#888888" if QtGui.QColor(BASECOLOR).valueF() < 0.5: # dark page - we need to make darker shadows SHADOW = "#000000" @@ -750,7 +753,6 @@ def handle(): HTML = HTML.replace("SHADOW", SHADOW) HTML = HTML.replace("FONTFAMILY", FONTFAMILY) HTML = HTML.replace("FONTSIZE", str(FONTSIZE) + "px") - HTML = HTML.replace("OVERFLOW", OVERFLOW) # enable web access if permitted diff --git a/src/Mod/Start/StartPage/TranslationTexts.py b/src/Mod/Start/StartPage/TranslationTexts.py index 1f33d53ab8..0750b19d96 100644 --- a/src/Mod/Start/StartPage/TranslationTexts.py +++ b/src/Mod/Start/StartPage/TranslationTexts.py @@ -41,12 +41,12 @@ T_DOCUMENTS = translate("StartPage", "Documents") T_HELP = translate("StartPage", "Help") T_ACTIVITY = translate("StartPage", "Activity") T_BLOG = translate("StartPage", "Blog") -T_BLOG_TOOLTIP = translate("StartPage", "Link to the FreeCAD blog") +T_TOOLTIP_BLOG = translate("StartPage", "Link to the FreeCAD blog") T_NEWFILE = translate("StartPage", "New file") T_TEMPLATE_EMPTYFILE_NAME = translate("StartPage", "Empty File") T_TEMPLATE_EMPTYFILE_DESC = translate("StartPage", "Create an empty FreeCAD file") -T_TEMPLATE_IMPORTFILE_NAME = translate("StartPage", "Import File") -T_TEMPLATE_IMPORTFILE_DESC = translate("StartPage", "Work on an existing CAD file or 3D model") +T_TEMPLATE_OPENFILE_NAME = translate("StartPage", "Open File") +T_TEMPLATE_OPENFILE_DESC = translate("StartPage", "Open an existing CAD file or 3D model") T_TEMPLATE_PARAMETRICPART_NAME = translate("StartPage", "Standard Part") T_TEMPLATE_PARAMETRICPART_DESC = translate( "StartPage", "Create a part with the Part Design workbench" diff --git a/src/Mod/Start/StartPage/images/new_import_file.png b/src/Mod/Start/StartPage/images/new_open_file.png similarity index 100% rename from src/Mod/Start/StartPage/images/new_import_file.png rename to src/Mod/Start/StartPage/images/new_open_file.png