Reading PDF in landscape mode on Kindle Touch

Current version of firmware for Kindle Touch lacks support of landscape mode. WTF! There is jailbreak already, but no any lanscape hack. What will be very usefull for reading pdf. So, if there is no way to make it directly on Kindle, we will make it for Kindle)
I'm use k2pdfopt like this:
k2pdfopt.exe -col 1 -j 0+ -ls -ui -fc- -odpi 130 -h 711 -w 521 -om 0 -cmax 1 -s- -rt 0 -mb 0.7 %1

Let's look at them in detail:
  • -col 1 - means that there is no need to find any columns in text. If you have tables, this will helps to not break them to columns at new pages
  • -j 0+ - tries to justification text left
  • -ls - rotate page to landscape
  • -ui - run UI for making additional tuning before converting
  • -fc - don't fit columns to width
  • -odpi 130 - slightly zooming of input file
  • -h 711-w 521 - width and height of screen zone for displaying pdf. There is table for other readers.
  • -om 0 -disable output margin, Kindle Touch already has margin about 10px near pdf displaying zone
  • -cmax 1 -s- - disable increasing of contrast and sharpening. This makes fonts looks more like ClearType, with soft edges.
  • -rt 0 - disable auto determination of source orientation
  • -mb 0.7 - cut bottom margin of source in inches. This is for cutting original footer with page number etc on every source page.
  • %1 - name of source pdf
You can save this as .cmd file, and drag'n'drop your pdf files over.
Examples of source:

and 2 pages of zoomed output:



Some bash hotkeys:
Ctrl + A  Go to the beginning of the line you are currently typing on
Ctrl + E  Go to the end of the line you are currently typing on
Ctrl + L  Clears the Screen, similar to the clear command
Ctrl + U  Clears the line before the cursor position. If you are at the end of the line, clears the entire line.
Ctrl + R  Let’s you search through previously used commands
Ctrl + C  Kill whatever you are running
Ctrl + D  Exit the current shell
Ctrl + Z  Puts whatever you are running into a suspended background process. "fg" restores it.
Ctrl + W  Delete the word before the cursor
Ctrl + K  Clear the line after the cursor
Ctrl + T  Swap the last two characters before the cursor
Esc + T  Swap the last two words before the cursor
Some notes about reverse history search. It'll iterative show last command for your search query. For next item press Ctrl-R again. To search forward press Ctrl-S. (On some terminals this bind to freeze, press Ctrl-Q to defreeze) More about history navigation here

Using screen:


Debian domain join

How to join Debian Squeeze to Active Directory Domain (winbind method).This makes possible to login as domain user, make samba shares with domain security, ntlm SSO to Apache sites, ntlm auth with Squid proxy.


Mail notifications by GMail from Debian

Описание настройки Debian Exim4 для рассылки почты через GMail apps for domain для получения уведомлений на почту из cron и скриптов.

Turn windows Home to Professional

Заметка для себя, дабы больше не гуглить. Минимальная версия Windows для подключения к домену - Pro.


Punto Switcher msi for GPO deployment

Сборка Punto Switcher 3.2.5 в пакет msi для установки в домене. Изменения:
  • Удален yandex update
  • При установке пытается удалить другие версии PuntoSwitcher вместе с настойками, и ярлыки в меню Пуск
  • Настройки сохраняются в папке с программой в \User Data\ для всех локальных юзеров. При установке даются права записи на эту папку для юзеров.
  • Настройки по умолчанию: автопереключение выкл., звуки выкл, Win+S убран, добавлен Shift+ScrollLock для истории буфера обмена.
  • В исключения программ добавлен IrfanView
Download Punto Switcher msi

MPC-HC msi package for GPO deployment

This is a Media Player Classic Home Cinema msi package for mass deployment in AD by Group Policy. Customizations from original version:
  • Video files associations on install for all users
  • All internal audio/video codecs enabled by default
  • Settings saved in mpc-hc.ini file for all users. When installed write rights assigned to this file for all local users
Download MPC-HC.msi
Скачать MPC-HC.msi с русским языком по умолчанию


Firefox msi for GPO deployment

This is a custom msi package of Firefox 6.0.2 with some plugins for mass deployment in AD by Group Policy. Customizations from original version:
  • Installed plugins:
    GPO for Firefox - apply GroupPolicy settings assigned by adm/admx to Firefox (Here used GPO for Firefox v0.9.3 modified by me.)
    IETab - opens selected sites by IE engine inside Firefox tab
    Adblock Plus - block advertisement, banners etc
  • Tweaked default interface:

    Disabled text menu, cleared statusbar, Adblock button moved to top bar
  • Sets as default browser for all users
  • No asking about import of IE bookmarks on first run
  • No any browser information / plug-in notification tabs open on first run. Home page only.
  • Auto-updates enabled by default. You need to give write rights for users to folder
    %ProgramFiles%\Mozilla Firefox
    for auto-updates works under user. This could be done by GPO settings (Windows configuration  / Security / File system)
  • Modified firefox.adm GPP policy included. Added localfilelinks policy for opening intranet links to local resources, like file:\\\o:\path\file as described here
Download Firefox_en.msi
Скачать Firefox.msi русский. (Как сделать такую сборку самому - http://habrahabr.ru/blogs/sysadm/128161/)


IrfanView msi package for GPO deployment

This is a custom msi package of IrfanView v4.30 with some plugins for mass deployment in AD by Group Policy. Customizations from original version:
  • Auto file association only for images
  • Installs additional plugins only for image types (Postscript.dll, Jpg_transform.dll, IPTC.dll, Formats.dll, Exif.dll, ImPDF.dll, JPEG2000.dll, Mrc.dll, Hdp.dll, Awd.dll, Wbz.dll, Riot.dll, Lcms.dll, Ecw.dll, Jpeg_LS.dll, Jpm.dll, Wsq.dll, Crw.dll, Exr.dll, Sff.dll, Lwf.dll, Ldf.dll, Ics.dll, Fpx.dll, DjVu.dll, B3d.dll, Dicom.dll, Vtf.dll, Pngout.dll, Icons.dll, EAFSH.dll, LogoManager.dll, Photocd.dll, KDC120.dll)
  • Custom icons.dll for file types icons in explorer (No red dead cat anymore! :)
  • Leila 16x16 toolbar icons
  • Removes old folder %ProgramFiles%\IrfanView
  • Removes old link folder or shortcut %StartMenu%\IrfanView(.lnk)
  • No desktop shortcut, only one at %StartMenu%\IrfanView.lnk
If you don't want to distribute it by GPO, just simple silent install from command prompt - use example commands:
msiexec /i \\server\path\IrfanView.msi /passive will give you only progressbar without Cancel button
msiexec /i \\server\path\IrfanView.msi /quiet totally silent install

Download IrfanView.msi
Скачать IrfanView.msi  с русским языком по умолчанию


Adobe Flash and Adobe Reader msi packets

Some quick info about getting Adobe Flash and Adobe Reader installers in msi form for distributing in AD by GPO.