Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bring in Ondsel changes #335

Open
wants to merge 18 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
26 changes: 0 additions & 26 deletions Init.py

This file was deleted.

4 changes: 2 additions & 2 deletions InitGui.py
Original file line number Diff line number Diff line change
Expand Up @@ -99,8 +99,8 @@ def Initialize(self):
FreeCAD.Qt.translate("SheetMetal", "&Sheet Metal"), self.list
) # creates a new menu
# self.appendMenu(["An existing Menu","My submenu"],self.list) # appends a submenu to an existing menu
FreeCADGui.addPreferencePage(os.path.join(smWBpath, "SMprefs.ui"), "SheetMetal")
FreeCADGui.addIconPath(smWB_icons_path)
Gui.addPreferencePage(os.path.join(smWBpath, "Resources/panels/SMprefs.ui"), "SheetMetal")
Gui.addIconPath(smWB_icons_path)

def Activated(self):
"This function is executed when the workbench is activated"
Expand Down
13 changes: 0 additions & 13 deletions BaseShapeOptions.ui → Resources/panels/BaseShapeOptions.ui
Original file line number Diff line number Diff line change
Expand Up @@ -623,19 +623,6 @@
</property>
</widget>
</item>
<item>
<widget class="QCheckBox" name="chkNewBody">
<property name="toolTip">
<string>Create the base shape as a new body</string>
</property>
<property name="text">
<string>Embed in new Body</string>
</property>
<property name="checked">
<bool>true</bool>
</property>
</widget>
</item>
<item>
<spacer name="verticalSpacer">
<property name="orientation">
Expand Down
132 changes: 132 additions & 0 deletions Resources/panels/BendOnLinePanel.ui
Original file line number Diff line number Diff line change
@@ -0,0 +1,132 @@
<?xml version="1.0" encoding="UTF-8"?>
<ui version="4.0">
<class>SMCreateBaseShapeTaskPanel</class>
<widget class="QDialog" name="SMCreateBaseShapeTaskPanel">
<property name="geometry">
<rect>
<x>0</x>
<y>0</y>
<width>677</width>
<height>565</height>
</rect>
</property>
<property name="windowTitle">
<string>Generate Sheet Metal base shape</string>
</property>
<layout class="QVBoxLayout" name="verticalLayout">
<item>
<widget class="QFrame" name="frame">
<property name="frameShape">
<enum>QFrame::StyledPanel</enum>
</property>
<property name="frameShadow">
<enum>QFrame::Raised</enum>
</property>
<layout class="QGridLayout" name="gridLayout">
<item row="0" column="2">
<widget class="QLineEdit" name="txtBaseObject"/>
</item>
<item row="1" column="0">
<widget class="QLabel" name="label_2">
<property name="text">
<string>Bend Line</string>
</property>
</widget>
</item>
<item row="0" column="0">
<widget class="QLabel" name="label">
<property name="text">
<string>Base Object</string>
</property>
</widget>
</item>
<item row="2" column="0">
<widget class="QLabel" name="label_3">
<property name="text">
<string>Feature Name</string>
</property>
</widget>
</item>
<item row="1" column="2">
<widget class="QLineEdit" name="txtBendLine"/>
</item>
<item row="2" column="2">
<widget class="QLineEdit" name="txtFeatureName_2"/>
</item>
</layout>
</widget>
</item>
<item>
<layout class="QHBoxLayout" name="horizontalLayout">
<item>
<widget class="QPushButton" name="btnFlipDirection">
<property name="text">
<string>Flip Direction</string>
</property>
</widget>
</item>
<item>
<widget class="QPushButton" name="btnUnbend">
<property name="text">
<string>Unbend</string>
</property>
</widget>
</item>
</layout>
</item>
<item>
<widget class="QFrame" name="frame">
<layout class="QGridLayout" name="gridLayout_2">
<item row="0" column="0">
<widget class="QLabel" name="label_4">
<property name="text">
<string>Bend Radius</string>
</property>
</widget>
</item>
<item row="0" column="1">
<widget class="Gui::PrefUnitSpinBox" name="unitBendRadius"/>
</item>
<item row="1" column="1">
<widget class="Gui::PrefUnitSpinBox" name="unitBendAngle"/>
</item>
<item row="1" column="0">
<widget class="QLabel" name="label_5">
<property name="text">
<string>Bend Angle</string>
</property>
</widget>
</item>
</layout>
</widget>
</item>
<item>
<spacer name="verticalSpacer">
<property name="orientation">
<enum>Qt::Vertical</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>20</width>
<height>40</height>
</size>
</property>
</spacer>
</item>
</layout>
</widget>
<customwidgets>
<customwidget>
<class>Gui::QuantitySpinBox</class>
<extends>QWidget</extends>
<header>Gui/QuantitySpinBox.h</header>
</customwidget>
<customwidget>
<class>Gui::PrefUnitSpinBox</class>
<extends>Gui::QuantitySpinBox</extends>
<header>Gui/PrefWidgets.h</header>
</customwidget>
</customwidgets>
<resources/>
<connections/>
</ui>
151 changes: 151 additions & 0 deletions Resources/panels/CornerReliefPanel.ui
Original file line number Diff line number Diff line change
@@ -0,0 +1,151 @@
<?xml version="1.0" encoding="UTF-8"?>
<ui version="4.0">
<class>SMCreateBaseShapeTaskPanel</class>
<widget class="QDialog" name="SMCreateBaseShapeTaskPanel">
<property name="geometry">
<rect>
<x>0</x>
<y>0</y>
<width>677</width>
<height>565</height>
</rect>
</property>
<property name="windowTitle">
<string>Generate Sheet Metal base shape</string>
</property>
<layout class="QVBoxLayout" name="verticalLayout">
<item>
<widget class="QFrame" name="frame">
<property name="frameShape">
<enum>QFrame::StyledPanel</enum>
</property>
<property name="frameShadow">
<enum>QFrame::Raised</enum>
</property>
<layout class="QGridLayout" name="gridLayout">
<item row="0" column="1">
<widget class="QLabel" name="label">
<property name="text">
<string>Relief Size</string>
</property>
</widget>
</item>
<item row="0" column="3">
<widget class="Gui::PrefUnitSpinBox" name="unitReliefSize"/>
</item>
<item row="0" column="0">
<spacer name="horizontalSpacer">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>40</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
</layout>
</widget>
</item>
<item>
<layout class="QHBoxLayout" name="horizontalLayout">
<item>
<spacer name="horizontalSpacer_2">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>40</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
<item>
<widget class="QLabel" name="label_2">
<property name="text">
<string>Relief Type</string>
</property>
</widget>
</item>
<item>
<widget class="QFrame" name="frame">
<layout class="QVBoxLayout" name="verticalLayout_2">
<item>
<widget class="QRadioButton" name="radioButton">
<property name="text">
<string>Circular</string>
</property>
<property name="checked">
<bool>true</bool>
</property>
</widget>
</item>
<item>
<widget class="QRadioButton" name="radioButton_2">
<property name="text">
<string>Square</string>
</property>
</widget>
</item>
<item>
<widget class="QCheckBox" name="checkBox">
<property name="text">
<string>Scaling</string>
</property>
</widget>
</item>
<item>
<widget class="QLabel" name="label_3">
<property name="text">
<string>Scale Factor</string>
</property>
</widget>
</item>
<item>
<widget class="Gui::PrefUnitSpinBox" name="unitSpinBox"/>
</item>
</layout>
</widget>
</item>
</layout>
</item>
<item>
<widget class="QFrame" name="frame">
<layout class="QGridLayout" name="gridLayout_2">
<item row="0" column="0">
<spacer name="verticalSpacer">
<property name="orientation">
<enum>Qt::Vertical</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>20</width>
<height>40</height>
</size>
</property>
</spacer>
</item>
</layout>
</widget>
</item>
</layout>
</widget>
<customwidgets>
<customwidget>
<class>Gui::QuantitySpinBox</class>
<extends>QWidget</extends>
<header>Gui/QuantitySpinBox.h</header>
</customwidget>
<customwidget>
<class>Gui::PrefUnitSpinBox</class>
<extends>Gui::QuantitySpinBox</extends>
<header>Gui/PrefWidgets.h</header>
</customwidget>
</customwidgets>
<resources/>
<connections/>
</ui>
Loading