From 3aefaeea9935a0af8d0d502276b31b02a4d6696e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jos=C3=A9=20Carlos=20Cuevas?= Date: Tue, 22 Sep 2020 23:58:50 +0200 Subject: [PATCH] More gui, imports and remove support for lesser ;-) OSes --- gui.py | 9 +- res/smallprint.gtkbuilder | 222 +++++++++++++++++++++++--------------- 2 files changed, 136 insertions(+), 95 deletions(-) diff --git a/gui.py b/gui.py index ab3106b..c65411a 100644 --- a/gui.py +++ b/gui.py @@ -1,5 +1,3 @@ -#!/usr/bin/env python - # Python imports import os.path import sys @@ -13,16 +11,15 @@ from gi.repository import Gtk, Gio import gettext import locale +# Printing library import +import smallprint + if os.path.exists('locale/po') and os.path.exists('res'): # We're in the development tree DIR = "locale/po/" RESOURCES = "res/" -elif sys.platform != 'win32' and sys.platform != 'darwin': - DIR = "/usr/share/locale/" - RESOURCES = "/usr/local/share/jsoninspector" - else: DIR = "po" RESOURCES = "res/" diff --git a/res/smallprint.gtkbuilder b/res/smallprint.gtkbuilder index e3440e6..94d22ad 100644 --- a/res/smallprint.gtkbuilder +++ b/res/smallprint.gtkbuilder @@ -30,34 +30,7 @@ False - gtk-new - True - False - True - True - - - - - gtk-open - True - False - True - True - - - - - gtk-save - True - False - True - True - - - - - gtk-save-as + gtk-preferences True False True @@ -83,64 +56,6 @@ - - - True - False - _Editar - True - - - True - False - - - gtk-cut - True - False - True - True - - - - - gtk-copy - True - False - True - True - - - - - gtk-paste - True - False - True - True - - - - - gtk-delete - True - False - True - True - - - - - - - - - True - False - _Ver - True - - True @@ -206,14 +121,143 @@ True False vertical + 5 - + + True + True + True + 5 + 5 + + + True + False + + + True + False + Print text file + + + True + True + 5 + 0 + + + + + True + False + gtk-file + 3 + + + False + True + 1 + + + + + + + True + True + 0 + - + + True + True + True + 5 + 4 + + + True + False + + + True + False + Print image file + + + True + True + 5 + 0 + + + + + True + False + gtk-orientation-landscape + 6 + + + False + True + 1 + + + + + + + False + True + 5 + 1 + - + + True + True + True + + + True + False + + + True + False + Print PDF file + + + True + True + 5 + 0 + + + + + True + False + gtk-select-all + 3 + + + False + True + 1 + + + + + + + False + True + 2 +