The KOMA-Script bundle provides an option to specify the amount of binding correction needed in order to compensate for the width lost in the binding process. By default, it is added to the left margin, which is where the binding is applied for Left to Right languages. However, if a document is written in Hebrew or Arabic, one binds it on the right. The KOMA-Script manual does not consider that option. After a bit of playing I’ve found out that simply using a negative value for the binding correction works.
For example, if in an English document you would use
For Hebrew you would set
I’ve made available in my personal repository
amd64 builds of LyX 2.2.1 for Debian Jesie.
OrderNet is a a popular stock trading platform in Israel. OrderNet comes in two versions: The regular version is based on Silverlight and can be used on Linux using Pipelight. The Pro version is a desktop program written in .NET Framework and features better interface. This post walks through the steps needed to get OrderNet Pro running on Debian Jessie using Wine.
OrderNet Pro on Debian Jessie.
OrderNet Pro running on Debian Jessie.
I’ve backported LyX 2.2.0-2 from Debian Testing to Jessie. The binaries for
amd64 can be found in https://www.guyrutenberg.com/debian/jessie.
You can add my repository by appending the following line to
deb https://www.guyrutenberg.com/debian/jessie ./
From time to time I build and backport
deb packages. Most of them are for my personal use, but sharing them would be nice. Another advantage for setting up a personal repository over directly installing
deb files is that you can install dependencies from that repository automatically. Especially useful if one source package builds multiple binary packages which depend on one another.
There is a list of programs ways how to setup such personal repository in the Debian wiki. However, I found most ways to be too cumbersome for my limited requirements. The way I’m describing below is probably the simplest and easiest way to get up and running.
First thing is installing
dpkg-dev which provides
sudo apt install dpkg-dev
Next put the
deb files you created in some local repository such as
cd into it.
# dpkg-scanpackages -m . | gzip -c > Packages.gz
will scan all the
*.deb files in the directory and create an appropriate
Packages.gz file. You need to repeat this step whenever you add new packages to
Finally to enable the new local repository, add the following line to
deb [trusted=yes] file:///usr/local/debian ./
[trusted=yes] options instruct
apt to treat the packages as authenticated. Alternatively, if you want to share it with others, make sure that your webserver serves the directory and point to it
deb https://www.guyrutenberg.com/debian/jessie ./
(You will need the
apt-transport-https in order to use https repositories).
Don’t forget to
apt update before trying to install packages from the new repository.
The Opus codec provides superior audio quality over codecs such as AAC, MP3 and Vorbis. Android has support for Opus since Android 5.0 (Lollipop). However, when I tried playing Opus files on My LG G4, it wouldn’t recognize the file as a media file at all. It turns out, that the default
.opus extension is not recognized by Android. The workaround is to change the extension to
.ogg. Generally speaking, this is technically correct, as most Opus streams are encapsulated by an Ogg container, however,
.opus is the recommended extension (but apparently not for Android).
Some application rely on Internet Explorer to provide HTML rendering capabilities. Wine implements the same functionality based on a custom version of Mozilla’s Gecko rendering engine (the same engine used in Firefox). In Debian Jessie you have a package called
libwine-gecko-2.24 (the version is part of the name) which provides this rendering engine for Wine. However, different versions of Wine require different versions of wine-gecko. The package provided in Debian Jessie, matches the Wine version provided by
wine-development from the main Jessie repository (1.7.29). Unfortunately wine-development from the jessie-backports if of version 1.9.8 and requires wine-gecko of version 2.44 which is not provided by any Debian repository. This will lead to errors like
Could not load wine-gecko. HTML rendering will be disabled.
and blank spaces where HTML content would be rendered in many applications.
The solution would be to manually install the required version of wine-gecko. We start by downloading the MSI binaries provided by Wine
$ wget https://dl.winehq.org/wine/wine-gecko/2.44/wine_gecko-2.44-x86.msi
$ wget https://dl.winehq.org/wine/wine-gecko/2.44/wine_gecko-2.44-x86_64.msi
Now install the required one, based on whether you are using 32bit or 64bit wine environment:
wine-development msiexec /i wine_gecko-2.44-x86.msi
(be sure the setup the correct
$WINEPREFIX if needed).
This fixes both the links to the PDFs and the embeding in the mailbox. Click on the “View Raw” to install.
JPEG is a lossy format, and naive rotation results in a loss of quality. JPEG does allow some lossless operations, such as rotation by 90 degrees and flipping, on the basic blocks (MCUs) that compromise the image. It also allows re-arranging those blocks. Using this lossless operation, it is possible to preform a lossless JPEG rotation. To do so, the rotated image mus meet some basic criteria like having it size a multiple of the MCU size (usually 16×16).
Not all programs preform a lossless JPEG rotation, so it is useful to be aware which does. I check a couple of commonly used program to see if they indeed preform lossless rotation. The testing procedure was:
- Start with the original JPEG photo.
- Rotate it once to the right using each program.
- Rotate a copy of the rotated photo back to the right using the same program.
- Compare using ImageMagick (
compare -metric ae) the results.
Gnome’s Image Viewer 3.14.1 is lossless
Digikam (4.4.0) is lossless, however rotating with Digikam’s Image Editor is lossy.
Shotwell (0.20.1) does lossy rotation.
Update: The new locale was committed to
glibc and should be part of
Most Israelis are literate in English, and for a large percentage of them, English is also the preferred language when it comes to computers. They prefer English, as it solves right-to-left issues and general inconsistencies (it might be annoying when some programs are translated ands some not). The downside is, that currently, the existing English locales are not suitable for Israel, as there are cultural differences:
- American English spelling is more common in Israel.
- The metric system is used, along with the relevant paper sizes (“A4” instead of Letter).
- Dates are written in dd/mm/YYYY format, unlike in the USA.
- The first day of week, and also the first workday is Sunday.
- The currency used is ILS (₪).
So, up until now users had to choose locales such as en_US or en_GB and compromise on some stuff. To solve this issue, and create a truly suitable English locale for Israel, I wrote a
localedef file for the en_IL locale.
To install the new locale, copy the
en_IL file from the gist below and place under
/usr/share/i18n/locales/en_IL (no extension). Next
# echo "en_IL.UTF-8 UTF-8" >> /usr/local/share/i18n/SUPPORTED
Now, complete the installation by running
dpkg-reconfigure locales and enable
en_IL.UTF-8 from the list, and set it as the default locale.