Commit 31c6745d authored by Anton Fosselius's avatar Anton Fosselius

improved styling

parent 02c21d3c
......@@ -11,12 +11,14 @@ class ExampleModalGuiClass(QtGui.QDialog):
self.model.clear()
self.bodyList = []
for documents in App.listDocuments().values():
objectList = documents.findObjects("PartDesign::Body")
objectList += documents.findObjects("App::Part")
#print documents.Label
for body in documents.findObjects("PartDesign::Body"):
for body in objectList:
#print documents.Label + " " + body.Label
self.bodyList.append(body)
item = QtGui.QStandardItem(documents.Label + "->" + body.Label)
item.setIcon(body.ViewObject.Icon)
# Add a checkbox to it
item.setCheckable(False)
......@@ -27,22 +29,27 @@ class ExampleModalGuiClass(QtGui.QDialog):
# Our main window will be a QListView
self.list = QtGui.QListView(self)
self.list.move(0,40)
self.setWindowTitle('Import Link')
self.setMinimumSize(200, 400)
self.list.move(10,40)
self.setWindowTitle('Create Link')
self.setMinimumSize(400, 400)
# Create an empty model for the list's data
self.model = QtGui.QStandardItemModel(self)
self.list.setMinimumSize(200, 300)
self.list.setMinimumSize(380, 300)
self.textInput = QtGui.QLineEdit(self)
self.textInput.setMinimumSize(260, 0)
self.textInput.setMinimumSize(380, 0)
self.textInput.move(10,10)
self.reloadList()
self.linkNameInput = QtGui.QLineEdit(self)
self.linkNameInput.setMinimumSize(200, 0)
self.linkNameInput.move(10, 350)
#create link button
# toggle visibility button
self.createLinkButton = QtGui.QPushButton('Create Link', self)
self.createLinkButton.setAutoDefault(False)
self.createLinkButton.move(10, 350)
self.createLinkButton.move(210, 350)
self.model.itemChanged.connect(self.on_item_changed)
self.textInput.textChanged.connect(self.on_text_changed)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment