Skip to content

Commit

Permalink
Merge pull request #5 from glixx/master
Browse files Browse the repository at this point in the history
Some modifications
  • Loading branch information
thomasfuhringer committed Feb 19, 2019
2 parents 5acea4a + 511e5e3 commit e52606b
Show file tree
Hide file tree
Showing 49 changed files with 4,437 additions and 15 deletions.
2 changes: 1 addition & 1 deletion ChangeLog.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
Current Version 3.0.2
Current Version 3.0.4

Changes since 3.0.1

Expand Down
2 changes: 1 addition & 1 deletion PKG-INFO
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Metadata-Version: 1.0
Name: lybniz
Version: 3.0.2
Version: 3.0.4
Summary: Graph Plotter
Home-page: github.com/thomasfuhringer/lybniz
Author: Thomas Führinger, Sam Tygier
Expand Down
4 changes: 4 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,3 +7,7 @@ Version 3 based on GTK+ 3.
Runs on Windows using MinGW

![](images/ScreenshotWin.png)

Translations

You're welcome to translate: https://www.transifex.com/Magic/lybniz
Binary file added locale/ast/LC_MESSAGES/lybniz.mo
Binary file not shown.
Binary file added locale/ca/LC_MESSAGES/lybniz.mo
Binary file not shown.
Binary file added locale/da/LC_MESSAGES/lybniz.mo
Binary file not shown.
Binary file added locale/de/LC_MESSAGES/lybniz.mo
Binary file not shown.
Binary file added locale/es/LC_MESSAGES/lybniz.mo
Binary file not shown.
Binary file added locale/et/LC_MESSAGES/lybniz.mo
Binary file not shown.
Binary file added locale/gl/LC_MESSAGES/lybniz.mo
Binary file not shown.
Binary file added locale/hr/LC_MESSAGES/lybniz.mo
Binary file not shown.
Binary file added locale/id/LC_MESSAGES/lybniz.mo
Binary file not shown.
Binary file added locale/it/LC_MESSAGES/lybniz.mo
Binary file not shown.
Binary file added locale/lt/LC_MESSAGES/lybniz.mo
Binary file not shown.
Binary file added locale/ms/LC_MESSAGES/lybniz.mo
Binary file not shown.
Binary file added locale/oc/LC_MESSAGES/lybniz.mo
Binary file not shown.
Binary file added locale/pl/LC_MESSAGES/lybniz.mo
Binary file not shown.
Binary file added locale/pt/LC_MESSAGES/lybniz.mo
Binary file not shown.
Binary file added locale/pt_BR/LC_MESSAGES/lybniz.mo
Binary file not shown.
Binary file added locale/ru/LC_MESSAGES/lybniz.mo
Binary file not shown.
Binary file added locale/sr/LC_MESSAGES/lybniz.mo
Binary file not shown.
Binary file added locale/sv/LC_MESSAGES/lybniz.mo
Binary file not shown.
Binary file added locale/uk/LC_MESSAGES/lybniz.mo
Binary file not shown.
19 changes: 13 additions & 6 deletions lybniz.py → lybniz
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
import gi
gi.require_version("Gtk", "3.0")
from gi.repository import Gtk, Gdk, GObject, Pango, Gio, GdkPixbuf
from pathlib import Path

app_version = "3.0.4"

Expand Down Expand Up @@ -341,7 +342,7 @@ def plot(self):
compiled_y1 = compile(y1.replace("^","**"), "", 'eval')
plots.append((compiled_y1, 0, (0, 0, 1), y1))
except:
set_statusbar("Function '" + y1 + "' is invalid.")
set_statusbar(_("Function") + " '" + y1 + "' " + _("is invalid."))
invalid_input = True
compiled_y1 = None
else:
Expand All @@ -352,7 +353,7 @@ def plot(self):
compiled_y2 = compile(y2.replace("^","**"),"",'eval')
plots.append((compiled_y2, 1, (1, 0, 0), y2))
except:
set_statusbar("Function '" + y2 + "' is invalid.")
set_statusbar(_("Function") + " '" + y2 + "' " + _("is invalid."))
invalid_input = True
compiled_y2 = None
else:
Expand All @@ -363,7 +364,7 @@ def plot(self):
compiled_y3 = compile(y3.replace("^","**"), "", 'eval')
plots.append((compiled_y3, 2, (0, 1, 0), y3))
except:
set_statusbar("Function '" + y3 + "' is invalid.")
set_statusbar(_("Function") + " '" + y3 + "' " + _("is invalid."))
invalid_input = True
compiled_y3 = None
else:
Expand Down Expand Up @@ -400,7 +401,7 @@ def plot(self):
self.prev_y[e[1]] = y_c
except:
#print ("Error at %d: %s" % (x, sys.exc_info()))
set_statusbar("Function '" + e[3] + "' is invalid at " + str(int(x)) + ".")
set_statusbar(_("Function") + " '" + e[3] + "' " + _("is invalid at") + " " + str(int(x)) + ".")
invalid_input = True
self.prev_y[e[1]] = None

Expand Down Expand Up @@ -529,7 +530,7 @@ def menu_toolbar_create():
menu_scale_style.append(menu_item_cust)

menu_help = Gtk.Menu()
menu_item_help = Gtk.MenuItem(label="_Help", use_underline=True)
menu_item_help = Gtk.MenuItem(label=_("_Help"), use_underline=True)
menu_item_help.set_submenu(menu_help)
menu_item_help.set_use_underline(True)

Expand Down Expand Up @@ -768,7 +769,13 @@ def quit_dlg(widget, event=None):
def show_yelp(widget):
try:
import os
os.system("yelp doc/lybniz.xml")
xml_file = Path("doc/lybniz.xml")
if xml_file.is_file():
os.system("yelp doc/lybniz.xml")
else:
xml_file = Path("/usr/share/gnome/help/lybniz/C/lybniz.xml")
if xml_file.is_file():
os.system("yelp /usr/share/gnome/help/lybniz/C/lybniz.xml")
#os.system("yelp /usr/share/gnome/help/lybniz/C/lybniz.xml")
#Gtk.show_uri(None, "lybniz", 0)
except:
Expand Down
10 changes: 7 additions & 3 deletions lybniz-i18n.sh
100644 → 100755
Original file line number Diff line number Diff line change
Expand Up @@ -6,14 +6,16 @@
echo "Starting script lybniz-i18n.sh"

A=`which xgettext`
if [ "$A" = "" ]
if [ -z "$A" ]
then
echo "Error: missing xgettext"
exit 1
fi

pushd po

echo "Creating POT file"
xgettext --language=Python --keyword=_ --keyword=N_ --output=lybniz.pot ../lybniz.py
xgettext --language=Python --keyword=_ --keyword=N_ --output=lybniz.pot ../lybniz
xgettext --language=Desktop --output=lybniz.pot ../lybniz.desktop --from-code=utf-8 -j
echo "Done for creating POT file."

Expand All @@ -26,7 +28,7 @@ echo "Done for merge translations."

echo "Compiling translations"
rm -rf ../locale
for lang in `ls|grep -v \.pot|grep -v lybniz-i18n|cut -d "." --fields=1`
for lang in `ls|grep -v \.pot|cut -d "." --fields=1`
do
echo " Compiling $lang"
mkdir -p ../locale/$lang/LC_MESSAGES
Expand All @@ -36,4 +38,6 @@ do
done
echo "Done for compiling translations."

popd

echo "Script lybniz-i18n.sh was finished."
14 changes: 14 additions & 0 deletions lybniz.1
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
.TH lybniz 1 "October 20, 2006"
.SH NAME
lybniz - mathematical function graph plotter
.SH DESCRIPTION
.PP
Lybniz is a simple desktop graph plotter. It can currently plot three
functions and allows you to navigate the plot. Functions are entered
in Python notation, eg sin(x)/x ; 2*x**2 + 3*x - 4.
.PP
.SH HOMEPAGE
https://github.com/thomasfuhringer/lybniz
.SH AUTHOR
This manual page was written by Varun Hiremath <varunhiremath@gmail.com>,
for the Debian project (but may be used by others).
6 changes: 5 additions & 1 deletion lybniz.desktop
Original file line number Diff line number Diff line change
Expand Up @@ -24,13 +24,15 @@ GenericName[hu]=Lybniz grafikonrajzoló
GenericName[it]=Plotter per grafici Lybniz
GenericName[ja]=Lybniz グラフプロッター
GenericName[ky]=Lybniz граф түзүүчү
GenericName[lt]=Lybniz grafiko braižymo įrankis
GenericName[ms]=Pemplot graf Lybniz
GenericName[nb]=Lybniz grafplotter
GenericName[oc]=Traçador de grafes Lybniz
GenericName[pl]=Ploter wykresów Lybniz
GenericName[pt]=Lybniz, Plotador de Gráficos
GenericName[ro]=Trasor de grafice Lybniz
GenericName[sl]=Lybniz, izrisovalnik grafov
GenericName[sr]=Лајбниц исцртавач графика функција
GenericName[es]=Dibujo de gráficos Lybniz
GenericName[sv]=Lybniz grafritare
GenericName[tr]=Lybniz Grafik Çizici
Expand Down Expand Up @@ -64,20 +66,22 @@ Comment[hu]=Grafikonok és függvények rajzolása
Comment[it]=Disegna grafici e funzioni
Comment[ja]=グラフと関数をプロットします
Comment[ky]=Графтарды жана функцияларды түзүү
Comment[lt]=Braižykite grafikus ir funkcijas
Comment[ms]=Plot graf dan fungsi
Comment[nb]=Plott grafer og funksjoner
Comment[oc]=Traçar de corbas de foncions e de grafes
Comment[pl]=Kreśli wykresy funkcji
Comment[pt]=Plotar gráficos e funções
Comment[ro]=Trasați curbe de funcții și grafice
Comment[sl]=Izrisujte grafe in funkcije
Comment[sr]=Исцртавајте графике и функције
Comment[es]=Dibuja gráficas y funciones
Comment[sv]=Rita grafer och funktioner
Comment[tg]=Функсияҳо ва диаграммаҳои Plot
Comment[tr]=Grafikler ve fonksiyonlar çizdir
Comment[uk]=Побудова графіків та функції
Comment[vi]=Vẽ đồ thị và hàm số
Exec=lybniz.py
Exec=lybniz
Terminal=false
StartupNotify=true
Type=Application
Expand Down
209 changes: 209 additions & 0 deletions po/ast.po
Original file line number Diff line number Diff line change
@@ -0,0 +1,209 @@
# SOME DESCRIPTIVE TITLE.
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
# This file is distributed under the same license as the PACKAGE package.
#
# Translators:
# AlexL <loginov.alex.valer@gmail.com>, 2019
# Xuacu Saturio <xuacusk8@gmail.com>, 2018
msgid ""
msgstr ""
"Project-Id-Version: lybniz\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2019-02-19 09:38+0300\n"
"PO-Revision-Date: 2019-02-19 05:22+0000\n"
"Last-Translator: AlexL <loginov.alex.valer@gmail.com>\n"
"Language-Team: Asturian (http://www.transifex.com/Magic/lybniz/language/"
"ast/)\n"
"Language: ast\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"

#: ../lybniz:345 ../lybniz:356 ../lybniz:367 ../lybniz:404
msgid "Function"
msgstr ""

#: ../lybniz:345 ../lybniz:356 ../lybniz:367
msgid "is invalid."
msgstr ""

#: ../lybniz:404
msgid "is invalid at"
msgstr ""

#: ../lybniz:439
msgid "_File"
msgstr "_Ficheru"

#: ../lybniz:443
msgid "_Save"
msgstr "_Guardar"

#: ../lybniz:443
msgid "Save graph as bitmap"
msgstr "Guardar la gráfica coma mapa de bits"

#: ../lybniz:450
msgid "_Quit"
msgstr "_Colar"

#: ../lybniz:450
msgid "Quit Application"
msgstr "Colar de l'aplicación"

#: ../lybniz:458
msgid "_Graph"
msgstr "G_ráfica"

#: ../lybniz:462
msgid "P_lot"
msgstr "_Trazar"

#: ../lybniz:462
msgid "Plot Functions"
msgstr "Funciones de trazáu"

#: ../lybniz:469
msgid "_Evaluate"
msgstr "_Evaluar"

#: ../lybniz:469
msgid "Evaluate Functions"
msgstr "Evaluar les funciones"

#: ../lybniz:476
msgid "Zoom _In"
msgstr "A_verar"

#: ../lybniz:476
msgid "Zoom In"
msgstr "Averar"

#: ../lybniz:483
msgid "Zoom _Out"
msgstr "All_oñar"

#: ../lybniz:483
msgid "Zoom Out"
msgstr "Alloñar"

#: ../lybniz:490
msgid "Zoom _Reset"
msgstr "_Reaniciar ampliación"

#: ../lybniz:490
msgid "Zoom Reset"
msgstr "Reaniciar ampliación"

#: ../lybniz:497
msgid "_Connect Points"
msgstr "_Conectar puntos"

#: ../lybniz:504
msgid "Scale Style"
msgstr "Estilu de la escala"

#: ../lybniz:508
msgid "Decimal"
msgstr "Decimal"

#: ../lybniz:508
msgid "Set style to decimal"
msgstr "Establecer l'estilu a decimal"

#: ../lybniz:514
msgid "Radians π"
msgstr ""

#: ../lybniz:514
msgid "Set style to radians"
msgstr "Establecer l'estilu a radianes"

#: ../lybniz:520
msgid "Radians τ"
msgstr ""

#: ../lybniz:520
msgid "Set style to radians using Tau (τ)"
msgstr ""

#: ../lybniz:526
msgid "Custom"
msgstr "Personalizáu"

#: ../lybniz:526
msgid "Set style to custom"
msgstr "Establecer l'estilu personalizáu"

#: ../lybniz:533
msgid "_Help"
msgstr "A_yuda"

#: ../lybniz:537
msgid "_Contents"
msgstr "_Conteníu"

#: ../lybniz:537
msgid "Help Contents"
msgstr "Conteníu de l'ayuda"

#: ../lybniz:544
msgid "_About"
msgstr "_Tocante a"

#: ../lybniz:544
msgid "About Box"
msgstr "Tocante a"

#: ../lybniz:608
msgid "Evaluate"
msgstr "Evaluar"

#: ../lybniz:735
msgid "Save as..."
msgstr "Guardar como..."

#: ../lybniz:790
msgid "Function Graph Plotter"
msgstr "Xenerador de gráfiques de función"

#: ../lybniz:858
msgid "X min"
msgstr "X min"

#: ../lybniz:863
msgid "Y min"
msgstr "Y min"

#: ../lybniz:875
msgid "X max"
msgstr "X max"

#: ../lybniz:881
msgid "Y max"
msgstr "Y max"

#: ../lybniz:893
msgid "X scale"
msgstr "escala X"

#: ../lybniz:898
msgid "Y scale"
msgstr "escala Y"

#: ../lybniz.desktop:3
msgid "Lybniz"
msgstr "Lybniz"

#: ../lybniz.desktop:4
msgid "Lybniz Graph Plotter"
msgstr "Xenerador de gráfiques Lybniz"

#: ../lybniz.desktop:42
msgid "Plot graphs and functions"
msgstr "Dibuxar gráfiques y funciones"

#: ../lybniz.desktop:90
msgid "lybniz"
msgstr "lybniz"
Loading

0 comments on commit e52606b

Please sign in to comment.