How to use the pygubu.Builder function in pygubu

To help you get started, we’ve selected a few pygubu examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github alejandroautalan / pygubu / tests / test_menu.py View on Github external
def setUp(self):
        support.root_deiconify()
        xmldata = 'test_menu.ui'
        self.builder = builder = pygubu.Builder()
        filepath = os.path.dirname(os.path.realpath(__file__))
        builder.add_resource_path(filepath)
        builder.add_from_file(xmldata)
        self.widget = builder.get_object('mainmenu')
github alejandroautalan / pygubu / tests / test_label.py View on Github external
ridge
        -- A Label --
        label_var
        20
        right
        
          0
          True
          0
        
      
    
  

"""
        self.builder = builder = pygubu.Builder()
        builder.add_from_string(xmldata)
        self.widget = builder.get_object('label')
github r-anime / holo / src / tools / editor.py View on Github external
def __init__(self):
		self.builder = pygubu.Builder()
		self.builder.add_from_file("editor.ui")
		self.mainwindow = self.builder.get_object("mainwindow")
		
		self.builder.connect_callbacks(self)
		self.mainwindow.protocol("WM_DELETE_WINDOW", self.on_close_window)
github alejandroautalan / pygubu / pygubudesigner / previewer.py View on Github external
def create_toplevel(self, widget_id, xmlnode):
        # Create preview
        builder = pygubu.Builder()
        builder.add_from_xmlnode(xmlnode)
        top = tk.Toplevel(self.canvas)
        top.columnconfigure(0, weight=1)
        top.rowconfigure(0, weight=1)

        menu = builder.get_object(widget_id, top)
        top['menu'] = menu
        return top
github alejandroautalan / pygubu / examples / menu.py View on Github external
def _create_ui(self):
        #1: Create a builder
        self.builder = builder = pygubu.Builder()

        #2: Load an ui file
        builder.add_from_file('menu.ui')

        #3: Create the widget using self.master as parent
        self.mainwindow = builder.get_object('mainwindow', self.master)

        # Set main menu
        self.mainmenu = menu = builder.get_object('mainmenu', self.master)
        self.set_menu(menu)

        # Configure callbacks
        builder.connect_callbacks(self)
github LinuxCabal / admin-cfdi / admincfdi.py View on Github external
def _init_var(self):
        self.builder = pygubu.Builder()
        self.config = self.util.load_config(self.g.FILES['config'])
        self.users_sat = {}
        self.mail_servers = {}
        self.users_xml = {}
        self.users_pdf = {}
        self.users_report = {}
        #~ self.reports = {}
        return
github alejandroautalan / pygubu / examples / cx_freeze / button_cb.py View on Github external
def __init__(self, master):
        self.builder = builder = pygubu.Builder()
        fpath = find_data_file("button_cb.ui")
        builder.add_from_file(fpath)

        mainwindow = builder.get_object('mainwindow', master)

        builder.connect_callbacks(self)

        callbacks = {
            'on_button2_clicked': self.on_button2_clicked
            }

        builder.connect_callbacks(callbacks)
github alejandroautalan / pygubu / examples / button_cb.py View on Github external
def __init__(self, master):
        self.builder = builder = pygubu.Builder()
        fpath = os.path.join(os.path.dirname(__file__),"button_cb.ui")
        builder.add_from_file(fpath)

        mainwindow = builder.get_object('mainwindow', master)

        builder.connect_callbacks(self)

        callbacks = {
            'on_button2_clicked': self.on_button2_clicked
            }

        builder.connect_callbacks(callbacks)
github bukharim96 / macron / core / wizard / __wizard__.py View on Github external
def navigate(self, next_view_ui):
    self.builder = Builder()
    self.builder.add_from_string(next_view_ui)
    self.mainwindow = self.builder.get_object('Frame_0', self.root)
    self.builder.connect_callbacks(self)
github alejandroautalan / pygubu / examples / py2exe / button_cb.py View on Github external
def __init__(self, master):
        self.builder = builder = pygubu.Builder()
        fpath = os.path.join(CDIR,"button_cb.ui")
        builder.add_from_file(fpath)

        mainwindow = builder.get_object('mainwindow', master)

        builder.connect_callbacks(self)

        callbacks = {
            'on_button2_clicked': self.on_button2_clicked
            }

        builder.connect_callbacks(callbacks)