TeXPrinter is a Java application designed for the sole purpose of printing threads from TeX.SX, a free, community driven Q&A for users of TeX, LaTeX, ConTeXt, and related typesetting systems. TeX.SX is a part of the Stack Exchange network of Q&A websites.
TeXPrint currently can print threads to the following formats:
The PDF output is provided by the iText library. It's a quick option if you don't intend to customize the output. If the thread has images, they are embedded in the final result.
The TeX option is recommended if you want to format the code the way you like it. It basically uses the
article style, the
listings package and a pretty straightforward approach. If the thread has images, they are downloaded to the current directory and correctly referenced in the document. Of course, you need to compile it.
Please note that only the main TeX.SX website is supported.
TeXPrinter is licensed under the New BSD License. I want to call your attention to the fact that the New BSD License has been verified as a GPL-compatible free software license by the Free Software Foundation, and has been vetted as an open source license by the Open Source Initiative.
That said, this application makes use of the following libraries with their respective licenses:
- iText PDF library: GNU Affero General Public License
- JSoup HTML parser: The MIT License
- MiG Layout: GNU General Public License / BSD License.
- Apache Commons CLI library: The Apache Software License Version 2.0
- Apache Commons Lang library: The Apache Software License Version 2.0
- Apache Commons Codec library: The Apache Software License Version 2.0
- Task Dialog: New BSD License.
Thanks to all these projects and developers involved.
Features and Usage
The first feature I have to mention about TeXPrinter is that this application runs on every major operating system, including Linux, Windows and MacOSX. In other words, the code is platform independent, it will run wherever there's a Java Virtual Machine. I tried to provide screenshots for those operating systems.
When runnning the application, this is the first screen you will see. I tried to keep it plain and simple. Just type the TeX.SX question identifier in the textfield and click OK. Please note that the user contributions are licensed under cc-wiki with attribution required. In case you don't know, the question identifier refers to the following pattern:
http://tex.stackexchange.com/questions/<ID>/.... In short, the identifier is a bunch of numbers.
If you managed to reach this screen, you are half way done. It's self-explanatory, just choose the output format you want. Currently you can choose between PDF and TeX for the reasons described in the Introduction section.
If nothing went wrong, you will reach this screen. The output format will be written in the current directory. For your convenience, you can include TeXPrinter in your system path and call it from any directory.
Didn't you read the previous info? The question identifier expects to be only numbers, unless of course Stack Exchange proves me wrong some day.
If you type ?, you will see this message with the application version, changelog and license. Please note that TeXPrinter can check if there is a newer version available. Due to security reasons, TeXPrinter won't auto-update itself, you need to download the new version from here. It's just a friendly note.
TeXPrinter is far from being bug-free. I worked hard to fix known bugs, but of course, there might be several bugs that I haven't discovered yet. If you find one of them, TeXPrinter allows you to send me an anonymous error report. It is basically a walkthrough execution plan, no sensible data is sent. It helps me a lot.
Some say a picture is worth a thousand words. Then I guess a video may be worth a thousand pictures. The following video shows TeXPrinter in action running on a Fedora 15 machine with GNOME 3. Click the following image to enlarge.
|TeXPrinter in action|
The song used in this video is Wired But Disconnected by duckett and it's licensed under Creative Commons Attribution Noncommercial Version 3.0.
TeXPrinter can also be used from the command line. If you simply type
java -jar texprinter.jar in your terminal, it will launch the GUI screen we just saw. To see the CLI options, use the
[paulo@sapientia ~]$ java -jar texprinter.jar --help TeXPrinter - A TeX.SX question printer Copyright (c) 2011, Paulo Roberto Massa Cereda All rights reserved. usage: texprinter [ --question-id ID --output EXT | --version | --help ] --help print the help message --output <EXT> the output format ('pdf' or 'tex') --question-id <ID> the TeX.SX question ID --version print the application version [paulo@sapientia ~]$
In the showcase video, you can see TeXPrinter being used from the command line as well as the GUI frontend.
You can download TeXPrinter in the project page hosted on SourceForge.net (those guys are great!). Both executable jar and source code are available for download or even SVN browsing. Alternatively, you can check the source code directly on the project directory also available on GitHub.com. You can fork the project, if you want to.
That's it, hope you like this application. Suggestions are always welcome. Don't forget to visit TeX.SX and contribute to our community. You'll see me there somewhere. Thanks for using TeXPrinter!