Skip to content

Commit

Permalink
Merge branch 'master' into releases/0.7 for release 0.7.1
Browse files Browse the repository at this point in the history
  • Loading branch information
jcwinkler committed Feb 6, 2018
2 parents bc6ab23 + 4b4de50 commit b5d38c5
Show file tree
Hide file tree
Showing 9 changed files with 101 additions and 56 deletions.
13 changes: 13 additions & 0 deletions CHANGELOG.txt
Original file line number Diff line number Diff line change
@@ -1,5 +1,18 @@
Version 0.7.1 (2018-02-06)
==========================
Fixed:
Wrong scaling so that text with explicitly defined font size does not match
size of text with equal font size in Inkscape 0.92.x (issue #1)

Fixed:
"Zero length field name in format" error in Inkcape <= 0.91 (issue #6)


---
Note: All issue references for version 0.7 and prior refer to
bitbucket.org/pitgarbe/textext
---


Version 0.7 (2017-12-15)
========================
Expand Down
42 changes: 23 additions & 19 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,20 +1,24 @@
# Tex Text 0.7 - A LaTeX extension for Inkscape (releases 0.92, 0.91 and 0.48)
# Tex Text 0.7.1 - A LaTeX extension for Inkscape (releases 0.92, 0.91 and 0.48)

TexText is a Python plugin for the vector graphics editor [Inkscape](http://www.inkscape.org) providing the possibility to add LaTeX generated SVG elements to your drawing. This repository continues the development of the plugin which took place at [https://bitbucket.org/pitgarbe/textext](https://bitbucket.org/pitgarbe/textext) until Junuary 2018. Originally TexText has been developed by [Pauli Virtanen](http://www.iki.fi/pav/software/textext/) based on the plugin InkLaTeX written by Toru Araki.
TexText is a Python plugin for the vector graphics editor [Inkscape](http://www.inkscape.org) providing the possibility to add LaTeX generated SVG elements to your drawing. This repository continues the development of the plugin which took place at [https://bitbucket.org/pitgarbe/textext](https://bitbucket.org/pitgarbe/textext) until January 2018. Originally, TexText had been developed by [Pauli Virtanen](http://www.iki.fi/pav/software/textext/) based on the plugin InkLaTeX written by Toru Araki.

![TexText dialog together with Inkscape](docs/readme-images/textext-with-inkscape.png)

### Very important - broken pstoedit support by ghostscript
On all platforms pstoedit support is broken by ghostscript releases 9.21 and later. Please make sure that you have ghostscript version 9.20 or prior installed! We are working hard for a fix by migrating the converter engine to pdf2svg or inkscape from the command line.
On all platforms pstoedit support is broken by ghostscript releases 9.21 and later. Please make sure that you have ghostscript version 9.20 or prior installed! We are working hard on a fix by migrating the converter engine to pdf2svg or the Inkscape command line itself.

**Note:** There are more sophisticated instructions, including pictures in the docs directory of this repository: [README-TexText.pdf](docs/README-TexText.pdf) or [README-TexText.html](docs/README-TexText.html)
**Note:** There are more sophisticated instructions, including pictures, in the docs directory of this repository: [README-TexText.pdf](docs/README-TexText.pdf) or [README-TexText.html](docs/README-TexText.html)

## Features
- Typesetting of beautiful equations using LaTeX which are placed as SVG objects in your document.
- LaTeX equation objects can be edited later (in contrast to the built in LaTeX-tool).
- Free scaling and coloring of the objects possible.
- Usage of user defined preamble files (e.g., to include special packages, etc.).

## New in relase 0.7.1 (2018-02-06)
- Fixed: Wrong scaling so that text with explicitly defined font size does not match size of text with equal font size in Inkscape 0.92.x (issue #1)
- Fixed: "Zero length field name in format" error in Inkcape <= 0.91 (issue #6)

## New in release 0.7 (2017-12-15)
- New: Compatibility with Inkscape 0.92.2 also under Windows
- New: Global and local scale factor. This feature enables the user to set the scale factor of a node to the value used while editing the previous node (Button "Global"). Hence, it is easier to change several nodes to the same scale factor. It is always possible to reset the scale factor to the value used for creating the node (Button "Reset").
Expand All @@ -36,14 +40,14 @@ On all platforms pstoedit support is broken by ghostscript releases 9.21 and lat

Download | SHA-256 Checksum
-------------|-------------------
[TexText-Linux-0.7.tgz](https://bitbucket.org/pitgarbe/textext/downloads/TexText-Linux-0.7.tgz) | 2c2c9aa1a7282b4ad5f3f146752b9d58b9f354fb0094137ee05af7a1eabd7af7
[TexText-Linux-0.7.zip](https://bitbucket.org/pitgarbe/textext/downloads/TexText-Linux-0.7.zip) | 3577bcd85d79ed708ebad9cca1c16763389a337833e9e85f90b2d08daa82835e
[TexText-Linux-0.7.1,tgz](https://github.com/textext/textext/releases/download/0.7.1/TexText-Linux-0.7.1.tgz) | 5f409bec9bdeb9ab2eff9d8608d518f7f1156cfcc187caef9638371b5c2a9bbb
[TexText-Linux-0.7.1.zip](https://github.com/textext/textext/releases/download/0.7.1/TexText-Linux-0.7.1.zip) | 64a9f8fd1ca35669e0389fd28528e71cdc4c4ce3bcdfb2720e033366c608c4e7

To install *Tex Text*, simply download the package and extract it. A directory with the name `textext-0.7-linux` will be created. Change into the directory and run `python setup.py` in your terminal. All it does, is copying the necessary files to your Inkscape extension directory. If you don't trust this script, you'll have to copy all the files within the `extensions` directory of the extracted archive to `~/.config/inkscape/extensions/`.
To install *Tex Text*, simply download the package and extract it. A directory with the name `textext-0.7.1-linux` will be created. Change into the directory and run `python setup.py` in your terminal. All it does, is copying the necessary files to your Inkscape extension directory. If you don't trust this script, you'll have to copy all the files within the `extensions` directory of the extracted archive to `~/.config/inkscape/extensions/`.

### Additional required software

- You'll need to install GtkSourceView (`python-gtksourceview2` on Ubuntu/Debian) to take advantage of all the GUI features of *Tex Text*. This package should install `python-gtk2` as well, but if your distribution works differently, make sure you install the Python Gtk+ bindings. Also ensure that the package `gnome-themes-standard` is installed to avoid anoying GTK-warnings after creating a LaTeX node.
- You'll need to install GtkSourceView (`python-gtksourceview2` on Ubuntu/Debian) to take advantage of all the GUI features of *Tex Text*. This package should install `python-gtk2` as well, but if your distribution works differently, make sure you install the Python Gtk+ bindings. Also ensure that the package `gnome-themes-standard` is installed to avoid annoying GTK-warnings after creating a LaTeX node.

- Next, please install `pstoedit`.

Expand All @@ -61,7 +65,7 @@ To install *Tex Text*, simply download the package and extract it. A directory w

Download | SHA-256 Checksum
------------|-------------------
[TexText-Windows-0.7.exe](https://bitbucket.org/pitgarbe/textext/downloads/TexText-Windows-0.7.exe) | 6f7edf8536a37b7de67f06d0ab3f1adbbc7e3d5e42ceb8a963c3945eb8dc583c
[TexText-Windows-0.7.1.exe](https://github.com/textext/textext/releases/download/0.7.1/TexText-Windows-0.7.1.exe) | c938c31e2136fd11a8c74cb3eb3f97d1ef4801503b2d3e0936803fcfc554a3d5

The installation of *Tex Text for Inkscape* is straightforward: Simply use the installer and follow the instructions (basically, click *Next*, *Install* and *Done*, since you usually won't even have to change the installation directory). It will copy the required files into the user's Inkscape configuration directory (usually this is `%USERPROFILE%\AppData\Roaming\Inkscape`) and put a key into the Windows registry which is used to store configuration data of the extension.

Expand All @@ -74,13 +78,13 @@ After that, you have to install PyGTK. Depending on your Inkscape version you ne

Inkscape Version (**important!**) | PyGTK Installer (SHA-256 Checksum)
-----------------------------------|-----------------------------------
Inkscape 0.92.2 - 64-bit | [Install-PyGTK-2.24-Inkscape-0.92.2-64bit.exe](https://bitbucket.org/pitgarbe/textext/downloads/Install-PyGTK-2.24-Inkscape-0.92.2-64bit.exe)
Inkscape 0.92.2 - 64-bit | [Install-PyGTK-2.24-Inkscape-0.92.2-64bit.exe](https://github.com/textext/textext/releases/download/0.7/Install-PyGTK-2.24-Inkscape-0.92.2-64bit.exe)
| c8e2e7551f253afb736a1f4f936a40dc116ad14bec7eac0c548b18a0a6e7e066
Inkscape 0.92.2 - 32-bit | [Install-PyGTK-2.24-Inkscape-0.92.2-32bit.exe](https://bitbucket.org/pitgarbe/textext/downloads/Install-PyGTK-2.24-Inkscape-0.92.2-32bit.exe)
Inkscape 0.92.2 - 32-bit | [Install-PyGTK-2.24-Inkscape-0.92.2-32bit.exe](https://github.com/textext/textext/releases/download/0.7/Install-PyGTK-2.24-Inkscape-0.92.2-32bit.exe)
| 7356f8d3232c038b2fff50d5cf608044c7c911db4f0b20d230bd5504a5cb20f9
Inkscape 0.92.0 and 0.92.1 (64- and 32-bit)| [Install-PyGTK-2.24-Inkscape-0.92.exe](https://bitbucket.org/pitgarbe/textext/downloads/Install-PyGTK-2.24-Inkscape-0.92.exe)
Inkscape 0.92.0 and 0.92.1 (64- and 32-bit)| [Install-PyGTK-2.24-Inkscape-0.92.exe](https://github.com/textext/textext/releases/download/0.7/Install-PyGTK-2.24-Inkscape-0.92.exe)
| a2ea5842084aa5f6fdc1880ae4ad135135f5ff0423bb0cd527a8f0cf95f7ffd6
Inkscape 0.91 and 0.48 (64- and 32-bit) | [Install-PyGTK-2.24-Inkscape-0.48+0.91.exe](https://bitbucket.org/pitgarbe/textext/downloads/Install-PyGTK-2.24-Inkscape-0.48+0.91.exe)
Inkscape 0.91 and 0.48 (64- and 32-bit) | [Install-PyGTK-2.24-Inkscape-0.48+0.91.exe](https://github.com/textext/textext/releases/download/0.7/Install-PyGTK-2.24-Inkscape-0.48+0.91.exe)
| 1189df2eb90d1229b850bbba75def3b39306f303f9e34415d34eaf58cda6a05c

The installer will search for your Inkscape installation and puts the required files into the directory of Inkscape. An uninstaller is installed by the installer, too.
Expand All @@ -89,13 +93,13 @@ If you do not trust the installer you can download one of the following zip arch

Inkscape Version | PyGTK zip-archive (SHA-256 Checksum)
------------------|-------------------------------------
Inkscape 0.92.2 - 64-bit | [PyGTK-2.24.2-Python-2.7-Inkscape-0.92.2-64bit.zip](https://bitbucket.org/pitgarbe/textext/downloads/PyGTK-2.24.2-Python-2.7-Inkscape-0.92.2-64bit.zip)
Inkscape 0.92.2 - 64-bit | [PyGTK-2.24.2-Python-2.7-Inkscape-0.92.2-64bit.zip](https://github.com/textext/textext/releases/download/0.7/PyGTK-2.24.2-Python-2.7-Inkscape-0.92.2-64bit.zip)
| db67a38bd4214e155446228cf0103b8d2b40e655c25b54574fab8f4f94a1dcdb
Inkscape 0.92.2 - 32-bit | [PyGTK-2.24.2-Python-2.7-Inkscape-0.92.2-32bit.zip](https://bitbucket.org/pitgarbe/textext/downloads/PyGTK-2.24.2-Python-2.7-Inkscape-0.92.2-32bit.zip)
Inkscape 0.92.2 - 32-bit | [PyGTK-2.24.2-Python-2.7-Inkscape-0.92.2-32bit.zip](https://github.com/textext/textext/releases/download/0.7/PyGTK-2.24.2-Python-2.7-Inkscape-0.92.2-32bit.zip)
| 7bc3e3123391827ac87e0be44a694959c7adf206b71af49a665ffe66b46ca8df
Inkscape 0.92.0 and 0.92.1 | [PyGTK-2.24.2-Python-2.7-Inkscape-0.92.zip](https://bitbucket.org/pitgarbe/textext/downloads/PyGTK-2.24.2-Python-2.7-Inkscape-0.92.zip)
Inkscape 0.92.0 and 0.92.1 | [PyGTK-2.24.2-Python-2.7-Inkscape-0.92.zip](https://github.com/textext/textext/releases/download/0.7/PyGTK-2.24.2-Python-2.7-Inkscape-0.92.zip)
| ff3dac6e6a01dfad1b4bfe831e8d363a06500c2673e5e692a36e0fdee065e2e0
Inkscape 0.91 and 0.48 | [PyGTK-2.24.2-Python-2.6-Inkscape-0.48+0.91.zip](https://bitbucket.org/pitgarbe/textext/downloads/PyGTK-2.24.2-Python-2.6-Inkscape-0.48+0.91.zip)
Inkscape 0.91 and 0.48 | [PyGTK-2.24.2-Python-2.6-Inkscape-0.48+0.91.zip](https://github.com/textext/textext/releases/download/0.7/PyGTK-2.24.2-Python-2.6-Inkscape-0.48+0.91.zip)
| 15f35a48d7b3558aadc9f8c7a2b9da8da0f66c8dfb88fb6c5e0230e58d64c080


Expand Down Expand Up @@ -143,10 +147,10 @@ There is a preview button as well, which shortens the feedback cycle from entry

## Known Issues

- Currently, colors set within the LaTeX code (`\textcolor{...}` in combination with an added `\usepackage{color}` in the preamble file) are irgnored.
- Currently, colors set within the LaTeX code (`\textcolor{...}` in combination with an added `\usepackage{color}` in the preamble file) are ignored.
- TexText fails to produce output if a ghostscript version later 9.20 is installed on your system. This is due to broken pstoedit support by ghostscript > 9.20 and cannot directly addressed by TexText.
- Under windows the Tkinter version of the GUI fails to open due to a bug in Inkscape. This will be fixed by the Inkscape team in Inkscape 0.92.3 Use the GTK interface instead.
- Under Inkscape 0.92 the fontsize selected in LaTeX does not match the font size in Inkscape if scale factor 1.0 is chosen (Issue #55 on [BitBucket](https://bitbucket.org/pitgarbe/textext/issues?status=new&status=open))
- Under Inkscape 0.92 the font size selected in LaTeX does not match the font size in Inkscape if scale factor 1.0 is chosen (Issue #55 on [BitBucket](https://bitbucket.org/pitgarbe/textext/issues?status=new&status=open))

## Release history

Expand Down
15 changes: 9 additions & 6 deletions asktext.py
Original file line number Diff line number Diff line change
Expand Up @@ -232,10 +232,10 @@ def ask(self, callback, preview_callback=None):
self._scale.set(self.scale_factor_after_loading())

reset_scale = self.current_scale_factor if self.current_scale_factor else self.global_scale_factor
self._reset_button = Tk.Button(box, text="Reset ({:.1f})".format(reset_scale),
self._reset_button = Tk.Button(box, text="Reset ({0:.1f})".format(reset_scale),
command=self.reset_scale_factor)
self._reset_button.pack(ipadx=10, ipady=4, pady=5, padx=5, side="left")
self._global_button = Tk.Button(box, text="Global ({:.1f})".format(self.global_scale_factor),
self._global_button = Tk.Button(box, text="Global ({0:.1f})".format(self.global_scale_factor),
command=self.use_global_scale_factor)
self._global_button.pack(ipadx=10, ipady=4, pady=5, padx=5, side="left")

Expand Down Expand Up @@ -636,8 +636,8 @@ def create_window(self):

# We need buttons with custom labels and stock icons, so we make some
reset_scale = self.current_scale_factor if self.current_scale_factor else self.global_scale_factor
items = [('tt-reset', 'Reset ({:.1f})'.format(reset_scale), 0, 0, None),
('tt-global', 'Global ({:.1f})'.format(self.global_scale_factor), 0, 0, None)]
items = [('tt-reset', 'Reset ({0:.1f})'.format(reset_scale), 0, 0, None),
('tt-global', 'Global ({0:.1f})'.format(self.global_scale_factor), 0, 0, None)]

# Forcibly show icons
settings = gtk.settings_get_default()
Expand All @@ -656,11 +656,14 @@ def create_window(self):
factory.add(new_stock, icon_set)

scale_reset_button = gtk.Button(stock='tt-reset')
scale_reset_button.set_tooltip_text("Set scale factor to the value this node has been created with ({:.1f})".format(reset_scale))
scale_reset_button.set_tooltip_text(
"Set scale factor to the value this node has been created with ({0:.1f})".format(reset_scale))
scale_reset_button.connect('clicked', self.reset_scale_factor)

scale_global_button = gtk.Button(stock='tt-global')
scale_global_button.set_tooltip_text("Set scale factor to the value of the previously edited node in Inkscape ({:.1f})".format(self.global_scale_factor))
scale_global_button.set_tooltip_text(
"Set scale factor to the value of the previously edited node in Inkscape ({0:.1f})".format(
self.global_scale_factor))
scale_global_button.connect('clicked', self.use_global_scale_factor)

scale_box.pack_start(self._scale, True, True, 2)
Expand Down
2 changes: 1 addition & 1 deletion build_linux_package.bat
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ rem subdirectory while the readme and setup-script are placed into
rem the "textext-[Version]-linux" directory

rem Some variables
set TexTextVersion=0.7
set TexTextVersion=0.7.1
set PackagePath=textext-%TexTextVersion%-linux
set ExtensionPath=%PackagePath%\extension
set PackageName=TexText-Linux-%TexTextVersion%
Expand Down
Loading

0 comments on commit b5d38c5

Please sign in to comment.