WIP: reboot for an UI
This commit is contained in:
parent
16cfd64e9b
commit
6cd611a5b4
|
@ -0,0 +1,12 @@
|
||||||
|
.PHONY: run install
|
||||||
|
|
||||||
|
sources=gemgraph.py gemgraph/main.py gemgraph/window.py
|
||||||
|
uis=ui/gemgraph.ui
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
install: ${sources} ${uis}
|
||||||
|
:
|
||||||
|
|
||||||
|
run: ${sources} ${uis}
|
||||||
|
./gemgraph.py
|
|
@ -0,0 +1,47 @@
|
||||||
|
#!/bin/python3
|
||||||
|
|
||||||
|
# Copyright (C) 2022 Libre en Communs <contact@a-lec.org>
|
||||||
|
# Copyright (C) 2022 Adrien Bourmault <neox@a-lec.org>
|
||||||
|
# Copyright (C) 2022 Jean Sirmai <jean@a-lec.org>
|
||||||
|
#
|
||||||
|
# This program is free software: you can redistribute it and/or modify
|
||||||
|
# it under the terms of the GNU General Public License as published by
|
||||||
|
# the Free Software Foundation, either version 3 of the License, or
|
||||||
|
# (at your option) any later version.
|
||||||
|
#
|
||||||
|
# This program is distributed in the hope that it will be useful,
|
||||||
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
|
# GNU General Public License for more details.
|
||||||
|
#
|
||||||
|
# You should have received a copy of the GNU General Public License
|
||||||
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
|
|
||||||
|
import os
|
||||||
|
import sys
|
||||||
|
import signal
|
||||||
|
import locale
|
||||||
|
import gettext
|
||||||
|
|
||||||
|
VERSION = '0.0.1'
|
||||||
|
#pkgdatadir = '@pkgdatadir@'
|
||||||
|
#localedir = '@localedir@'
|
||||||
|
|
||||||
|
#sys.path.insert(1, pkgdatadir)
|
||||||
|
signal.signal(signal.SIGINT, signal.SIG_DFL)
|
||||||
|
#locale.bindtextdomain('gemgraph', localedir)
|
||||||
|
#locale.textdomain('gemgraph')
|
||||||
|
#gettext.install('gemgraph', localedir)
|
||||||
|
|
||||||
|
if __name__ == "__main__" and __package__ is None:
|
||||||
|
__package__ = "gemgraph"
|
||||||
|
|
||||||
|
if __name__ == '__main__':
|
||||||
|
import gi
|
||||||
|
|
||||||
|
from gi.repository import Gio
|
||||||
|
#resource = Gio.Resource.load(os.path.join(pkgdatadir, 'gemgraph.gresource'))
|
||||||
|
#resource._register()
|
||||||
|
|
||||||
|
from gemgraph import main
|
||||||
|
sys.exit(main.main(VERSION))
|
|
@ -0,0 +1,28 @@
|
||||||
|
<?xml version='1.0' encoding='UTF-8' standalone='no'?>
|
||||||
|
<!DOCTYPE cambalache-project SYSTEM "cambalache-project.dtd">
|
||||||
|
<cambalache-project version="0.10.2" target_tk="gtk-4.0">
|
||||||
|
<ui>
|
||||||
|
(1,1,"gem-graph.ui","gem-graph.ui",None,None,None,None,None,None)
|
||||||
|
</ui>
|
||||||
|
<object>
|
||||||
|
(1,1,"GtkApplicationWindow","main",None,None,None,None,None),
|
||||||
|
(1,2,"AdwHeaderBar","main_titlebar",1,None,"titlebar",None,None),
|
||||||
|
(1,3,"GtkMenuButton","main_button_menu",2,None,"end",None,None),
|
||||||
|
(1,6,"GtkToggleButton","main_button_sidebar",2,None,None,None,2),
|
||||||
|
(1,7,"GtkPaned","main_paned",1,None,None,None,1),
|
||||||
|
(1,8,"GtkFrame","main_sideframe",7,None,None,None,None),
|
||||||
|
(1,9,"GtkFrame","main_frame",7,None,None,None,1),
|
||||||
|
(1,10,"GtkMenuButton","main_button_mode",2,None,"start",None,None)
|
||||||
|
</object>
|
||||||
|
<object_property>
|
||||||
|
(1,1,"GtkWindow","default-height","720",None,None,None,None,None),
|
||||||
|
(1,1,"GtkWindow","default-width","1080",None,None,None,None,None),
|
||||||
|
(1,1,"GtkWindow","icon-name","application-x-executable",None,None,None,None,None),
|
||||||
|
(1,1,"GtkWindow","title","Gem-graph 0.0.1",None,None,None,None,None),
|
||||||
|
(1,3,"GtkMenuButton","direction","none",None,None,None,None,None),
|
||||||
|
(1,6,"GtkButton","icon-name","sidebar-show-symbolic",None,None,None,None,None),
|
||||||
|
(1,7,"GtkPaned","position","250",None,None,None,None,None),
|
||||||
|
(1,10,"GtkMenuButton","always-show-arrow","True",None,None,None,None,None),
|
||||||
|
(1,10,"GtkMenuButton","icon-name","document-edit-symbolic",None,None,None,None,None)
|
||||||
|
</object_property>
|
||||||
|
</cambalache-project>
|
|
@ -0,0 +1,44 @@
|
||||||
|
<?xml version='1.0' encoding='UTF-8'?>
|
||||||
|
<!-- Created with Cambalache 0.10.2 -->
|
||||||
|
<interface>
|
||||||
|
<!-- interface-name gem-graph.ui -->
|
||||||
|
<requires lib="gtk" version="4.6"/>
|
||||||
|
<requires lib="libadwaita" version="1.1"/>
|
||||||
|
<template class="main" parent="GtkApplicationWindow">
|
||||||
|
<property name="default-height">720</property>
|
||||||
|
<property name="default-width">1080</property>
|
||||||
|
<property name="icon-name">application-x-executable</property>
|
||||||
|
<property name="title">Gem-graph 0.0.1</property>
|
||||||
|
<child type="titlebar">
|
||||||
|
<object class="AdwHeaderBar" id="main_titlebar">
|
||||||
|
<child type="end">
|
||||||
|
<object class="GtkMenuButton" id="main_button_menu">
|
||||||
|
<property name="direction">none</property>
|
||||||
|
</object>
|
||||||
|
</child>
|
||||||
|
<child type="start">
|
||||||
|
<object class="GtkMenuButton" id="main_button_mode">
|
||||||
|
<property name="always-show-arrow">True</property>
|
||||||
|
<property name="icon-name">document-edit-symbolic</property>
|
||||||
|
</object>
|
||||||
|
</child>
|
||||||
|
<child>
|
||||||
|
<object class="GtkToggleButton" id="main_button_sidebar">
|
||||||
|
<property name="icon-name">sidebar-show-symbolic</property>
|
||||||
|
</object>
|
||||||
|
</child>
|
||||||
|
</object>
|
||||||
|
</child>
|
||||||
|
<child>
|
||||||
|
<object class="GtkPaned" id="main_paned">
|
||||||
|
<property name="position">250</property>
|
||||||
|
<child>
|
||||||
|
<object class="GtkFrame" id="main_sideframe"/>
|
||||||
|
</child>
|
||||||
|
<child>
|
||||||
|
<object class="GtkFrame" id="main_frame"/>
|
||||||
|
</child>
|
||||||
|
</object>
|
||||||
|
</child>
|
||||||
|
</template>
|
||||||
|
</interface>
|
Loading…
Reference in New Issue