Permalink
Browse files

Removed pixmaps for generate buttons on headerbar

* Increased version
* Changed to setuptools from distutils
* More information about development on dialog
  • Loading branch information...
1 parent 97993af commit 634e70ebe55f399f574ebc8287b11a007a993ad1 @vfrico committed Nov 1, 2016
Showing with 129 additions and 233 deletions.
  1. +11 −9 pimagizer/gtkpimagizer.py
  2. +1 −1 pimagizer/info.py
  3. +3 −4 setup.py
  4. BIN src/percent.png
  5. +0 −82 src/percent.svg
  6. +114 −62 src/pimagizer.glade
  7. BIN src/px.png
  8. +0 −75 src/px.svg
@@ -307,20 +307,22 @@ def __init__(self, imputfile):
###############################################
# *** Buttons Pixels(px) and Percent(%)
+ big_format = '<span size="xx-large"><b>{}</b></span>'
self.buttonPx = Gtk.ToggleButton()
- imagePx = Gtk.Image.new_from_file("/usr/share/pimagizer/px.png")
- self.buttonPx.add(imagePx)
+ labelPx = Gtk.Label(big_format.format("Px"))
+ self.buttonPx.add(labelPx)
self.buttonPx.show()
- imagePx.show()
- # It is connected below
+ labelPx.set_use_markup(True)
+ labelPx.show()
+ # It is connected below
self.buttonPr = Gtk.ToggleButton()
- imagePr = Gtk.Image.new_from_file(
- "/usr/share/pimagizer/percent.png")
- self.buttonPr.add(imagePr)
+ labelPr = Gtk.Label(big_format.format("%"))
+ self.buttonPr.add(labelPr)
self.buttonPr.show()
- imagePr.show()
+ labelPr.set_use_markup(True)
+ labelPr.show()
# pr => box23
self.buttonPr.connect("toggled", self.toggledPr, self.buttonPx)
@@ -344,7 +346,7 @@ def __init__(self, imputfile):
self.hb.pack_end(box2)
- else: # Else "support headerbar"
+ else: # Else generate fake headerbar (for GTK =< 3.6)
self.buttonPr36 = self.builder.get_object("togglepr36")
self.buttonPx36 = self.builder.get_object("togglepx36")
View
@@ -1,5 +1,5 @@
#!/usr/bin/python
# -*- coding: UTF-8 -*-
name = 'pimagizer'
-version = "0.4.4"
+version = "0.4.5"
license = 'GPL-3'
View
@@ -22,7 +22,8 @@
#
import os
import shutil
-from distutils.core import setup
+# from distutils.core import setup
+from setuptools import setup
from pimagizer import info
setup(
name="pimagizer",
@@ -42,9 +43,7 @@
"src/pimagizer-main.png",
"src/neucha.ttf",
"src/images_zh_CN.png",
- "src/images_zh_TW.png",
- "src/px.png",
- "src/percent.png"]),
+ "src/images_zh_TW.png"]),
("/usr/share/applications/", ["src/pimagizer.desktop"]),
("/usr/share/icons/hicolor/scalable/apps/",
["src/pimagizer.svg"]),
View
Deleted file not rendered
View
@@ -1,82 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" standalone="no"?>
-<!-- Created with Inkscape (http://www.inkscape.org/) -->
-
-<svg
- xmlns:dc="http://purl.org/dc/elements/1.1/"
- xmlns:cc="http://creativecommons.org/ns#"
- xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
- xmlns:svg="http://www.w3.org/2000/svg"
- xmlns="http://www.w3.org/2000/svg"
- xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
- xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
- width="29.00177"
- height="28.766781"
- id="svg3021"
- version="1.1"
- inkscape:version="0.48.4 r9939"
- sodipodi:docname="percent.svg">
- <defs
- id="defs3023" />
- <sodipodi:namedview
- id="base"
- pagecolor="#ffffff"
- bordercolor="#666666"
- borderopacity="1.0"
- inkscape:pageopacity="0.0"
- inkscape:pageshadow="2"
- inkscape:zoom="7.9195959"
- inkscape:cx="33.035614"
- inkscape:cy="1.7273828"
- inkscape:document-units="px"
- inkscape:current-layer="text3029"
- showgrid="false"
- inkscape:window-width="1440"
- inkscape:window-height="835"
- inkscape:window-x="0"
- inkscape:window-y="27"
- inkscape:window-maximized="1"
- showguides="true"
- inkscape:guide-bbox="true"
- fit-margin-top="0"
- fit-margin-left="0"
- fit-margin-right="0"
- fit-margin-bottom="0" />
- <metadata
- id="metadata3026">
- <rdf:RDF>
- <cc:Work
- rdf:about="">
- <dc:format>image/svg+xml</dc:format>
- <dc:type
- rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
- <dc:title></dc:title>
- </cc:Work>
- </rdf:RDF>
- </metadata>
- <g
- inkscape:label="Capa 1"
- inkscape:groupmode="layer"
- id="layer1"
- transform="translate(-317.20394,-358.12111)">
- <g
- style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;line-height:125%;letter-spacing:0px;word-spacing:0px;fill:#000000;fill-opacity:1;stroke:none;font-family:Neucha;-inkscape-font-specification:Neucha"
- id="text3029">
- <path
- style="fill:#000000;font-family:Viga;-inkscape-font-specification:Viga"
- d="m 341.19044,358.12111 -14.71402,28.75 -4.08,0 14.71282,-28.74942"
- id="path3067"
- inkscape:connector-curvature="0"
- sodipodi:nodetypes="cccc" />
- <path
- id="path3065"
- style="fill:#000000;font-family:Viga;-inkscape-font-specification:Viga"
- d="m 342.44571,381.64789 0,-4.44 c -3e-5,-0.71999 -0.17337,-1.21332 -0.52,-1.48 -0.32003,-0.26666 -0.8267,-0.39999 -1.52,-0.4 -0.69336,10e-6 -1.21336,0.13334 -1.56,0.4 -0.32003,0.26668 -0.48003,0.76001 -0.48,1.48 l 0,4.44 c -3e-5,0.72 0.15997,1.21334 0.48,1.48 0.34664,0.26667 0.86664,0.4 1.56,0.4 0.6933,0 1.19997,-0.13333 1.52,-0.4 0.34663,-0.26666 0.51997,-0.76 0.52,-1.48 m 3.76,-5 0,5.56 c -4e-5,3.12 -1.93337,4.68 -5.8,4.68 -3.86669,0 -5.80002,-1.56 -5.8,-4.68 l 0,-5.56 c -2e-5,-3.11999 1.93331,-4.67999 5.8,-4.68 3.86663,10e-6 5.79996,1.56001 5.8,4.68"
- inkscape:connector-curvature="0" />
- <path
- inkscape:connector-curvature="0"
- id="path3065-6"
- style="font-size:40px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;line-height:125%;letter-spacing:0px;word-spacing:0px;fill:#000000;fill-opacity:1;stroke:none;font-family:Viga;-inkscape-font-specification:Viga"
- d="m 325.04394,367.81238 0,-4.44 c -3e-5,-0.71999 -0.17337,-1.21332 -0.52,-1.48 -0.32003,-0.26666 -0.8267,-0.39999 -1.52,-0.4 -0.69336,10e-6 -1.21336,0.13334 -1.56,0.4 -0.32003,0.26668 -0.48003,0.76001 -0.48,1.48 l 0,4.44 c -3e-5,0.72 0.15997,1.21334 0.48,1.48 0.34664,0.26667 0.86664,0.4 1.56,0.4 0.6933,0 1.19997,-0.13333 1.52,-0.4 0.34663,-0.26666 0.51997,-0.76 0.52,-1.48 m 3.76,-5 0,5.56 c -4e-5,3.12 -1.93337,4.68 -5.8,4.68 -3.86669,0 -5.80002,-1.56 -5.8,-4.68 l 0,-5.56 c -2e-5,-3.11999 1.93331,-4.67999 5.8,-4.68 3.86663,10e-6 5.79996,1.56001 5.8,4.68" />
- </g>
- </g>
-</svg>
Oops, something went wrong.

0 comments on commit 634e70e

Please sign in to comment.