Aug 8 2013

OsDown – A script to download subtitles

Lately I’ve been watching a lot of movies using Apple TV as a streamer.
I am using Beamer as the streaming app for my macbook air. Beamer also supports streaming with subtitles, which is a very cool feature, but you need to download the subtitles manually.

A year ago, I’ve built a Mac app called Sheeplayer which is a basic video player with the capabilities of downloading subtitles automatically from OpenSubtitles. Today I’ve decided to extract this capability into an independent script so I will be able to download the subtitles automatically to a given folder without executing any other program.

The script can be found at my github at: https://github.com/DiGMi/OsDown.


Jan 23 2012

Small tip for Hebrew LyX users – Stop the Gibberish

Are you using LyX with Hebrew?

Isn’t it annoying that when CAPSLOCK is on the entire text goes Gibberish?

The problem lays in the fact that by default some of the capital letters are mapped to the hebrew Niqqud characters. There for, when you type ‘S’ for example you will get a Dagesh.

How to solve it? Just edit: “C:\Program Files\LyX20\Resources\kbd\hebrew.kmap” (replace “C:\Program Files\LyX20\” with your installation folder) and comment all the lines (using # as comment) below the line:

# Hebrew points (nikud)

Restart LyX and we are done!


Dec 23 2011

Bug in LyX for Mac – \Omega, \otimes are not being displayed on designer

If you are using LyX on mac you probably noticed that some symbols are missing while editing an equation.

One of the symbols missing is $latex \Omega$ which is really annoying when you learn probability.
When you try and type \Omega, instead of seeing the symbol you will just see a blank space.

I’ve dived into the code, and found out how the all designer works. For most of the symbols, the translation is quite simple. There are several font files, and a file named symbols (located in /Application/LyX.app/Contents/Resources) which maps every latex code to the relevant font and unicode value.

The problem with $latex \Omega$ and $latex \otimes$ is that their unicode value is 0x00ad. And as it seems, QT4 has bug with characters with that code. LyX source code mentioned this bug in GuiPainter.cpp and it have some code to try and fix it, but for some reason it doesn’t work.

A work around for the $latex \Omega$ is to make a small change in the symbols file, locate the Omega line (with capital O) and change the code from 173 to 937 (a code for different Omega character that is available in the font).

I didn’t find (didn’t really looked for) a way to fix the \otimes, because i don’t really use it. A way to fix it will be using a font editor and changing the font and map the wanted symbols from other unused code. Again, didn’t care enough to do it, If someone want me to just post here. But I believe that LyX developers will soon enough fix it.