diff --git a/Gui test/gtk_test_1.py b/Gui test/gtk_test_1.py index 53f3dcd..517805f 100644 --- a/Gui test/gtk_test_1.py +++ b/Gui test/gtk_test_1.py @@ -16,7 +16,7 @@ class h2incGUI(Gtk.Window): Gtk.Window.__init__(self) self.set_title('Translate C-header files to Nasm include files!') self.set_default_size(200, 200) - self.set_border_width(5) + self.set_border_width(10) self.connect("destroy", Gtk.main_quit) self.sourcedir = 'Select source directory!' @@ -37,32 +37,37 @@ class h2incGUI(Gtk.Window): self.maingrid.add(self.frame) self.framegrid = Gtk.Grid() + self.framegrid.set_border_width(5) self.frame.add(self.framegrid) + self.sourcebox = Gtk.Box(orientation=Gtk.Orientation.HORIZONTAL, spacing=6) + self.framegrid.attach(self.sourcebox, 0, 0, 5, 1) + self.sourcelabel = Gtk.Label(label='Source: ') - self.framegrid.attach(self.sourcelabel, 1, 1, 1, 1) + self.sourcelabel.set_justify(Gtk.Justification.RIGHT) + self.sourcebox.add(self.sourcelabel) self.sourceentry = Gtk.Entry() self.sourceentry.set_text(self.sourcedir) - self.framegrid.attach(self.sourceentry, 2, 1, 1, 1) + self.sourcebox.add(self.sourceentry) self.sourcedir_button = Gtk.Button(label="Source directory...") #self.sourcedir_button.connect('clicked', self.select_sourcedir(self.sourcedir)) - self.framegrid.attach(self.sourcedir_button, 3, 1, 1, 1) + self.sourcebox.add(self.sourcedir_button) self.destbox = Gtk.Box(orientation=Gtk.Orientation.HORIZONTAL, spacing=6) - self.framegrid.attach(self.destbox, 1, 2, 1, 1) + self.framegrid.attach(self.destbox, 0, 1, 5, 1) self.destlabel = Gtk.Label(label='Destination: ') - self.framegrid.attach(self.destlabel, 2, 2, 1, 1) + self.destbox.add(self.destlabel) self.destentry = Gtk.Entry() self.destentry.set_text(self.destdir) - #self.destbox.add(self.destentry) + self.destbox.add(self.destentry) self.destdir_button = Gtk.Button(label="Destination directory...") #self.destdir_button.connect('clicked', self.select_destdir(self.destdir)) - #self.destbox.add(self.destdir_button) + self.destbox.add(self.destdir_button) self.incchkbox = Gtk.CheckButton('Create "include" folder if it does not exist.') self.incchkbox.set_active(False) diff --git a/__pycache__/h2inc.cpython-35.pyc b/__pycache__/h2inc.cpython-35.pyc index 2dec8fc..92eab8b 100644 Binary files a/__pycache__/h2inc.cpython-35.pyc and b/__pycache__/h2inc.cpython-35.pyc differ diff --git a/__pycache__/h2inc_gui.cpython-35.pyc b/__pycache__/h2inc_gui.cpython-35.pyc index 2867d00..b5fb497 100644 Binary files a/__pycache__/h2inc_gui.cpython-35.pyc and b/__pycache__/h2inc_gui.cpython-35.pyc differ diff --git a/h2inc.glade b/h2inc.glade new file mode 100644 index 0000000..4702fd7 --- /dev/null +++ b/h2inc.glade @@ -0,0 +1,393 @@ + + + + + + False + normal + select-folder + + + False + vertical + 2 + + + False + end + + + + + + + + + False + False + 0 + + + + + + + + + + False + 5 + 5 + 5 + 5 + + + True + False + + + True + False + 0 + etched-out + + + True + False + 12 + + + True + False + + + True + False + end + 5 + 5 + 5 + True + Source: + right + + + 0 + 0 + 2 + + + + + True + True + 5 + 5 + 5 + 5 + Select source directory! + + + 2 + 0 + 2 + + + + + Source directory... + True + True + True + start + 5 + 5 + 5 + 5 + + + 4 + 0 + 2 + + + + + True + False + False + end + 5 + 5 + 5 + True + Destination: + right + start + 2.2351741811588166e-10 + + + 0 + 1 + 2 + + + + + True + False + True + 5 + 5 + 5 + 5 + Select destination directory! + + + 2 + 1 + 2 + + + + + Destination directory... + True + False + True + True + start + 5 + 5 + 5 + 5 + + + 4 + 1 + 2 + + + + + Create "include" folder if it does not exist. + True + False + True + False + 5 + 5 + 0 + True + + + 0 + 2 + 6 + + + + + + + + + True + False + Select folders + + + + + 0 + 0 + 5 + + + + + True + False + False + 5 + 5 + 0 + etched-out + + + True + False + 12 + + + True + False + + + True + False + 5 + 5 + True + 0 + etched-out + + + True + False + 12 + + + True + False + vertical + + + True + False + start + 5 + 5 + True + Number of folders: 0 + + + False + True + 0 + + + + + True + False + start + 5 + 5 + Number of files: 0 + + + False + True + 1 + + + + + + + + + True + False + Source information + + + + + 0 + 0 + + + + + Translate! + True + True + True + start + 5 + 5 + + + 0 + 1 + + + + + True + False + 5 + 5 + 5 + 0 + etched-out + + + True + False + 12 + + + True + False + vertical + + + True + False + start + 5 + 5 + Total progress: + + + False + True + 0 + + + + + True + False + 5 + 5 + 5 + + + False + True + 1 + + + + + + + + + True + False + Progress + + + + + 0 + 2 + + + + + + + + + True + False + Translation + + + + + 0 + 1 + 5 + + + + + +