Browse Source

new archlinux setup with xmonad, uzbl, zsh...

master
James Wheaton 10 years ago
parent
commit
dfaad109f6

+ 14
- 0
.Xdefaults View File

@@ -0,0 +1,14 @@
URxvt*termName: rxvt-unicode
URxvt.buffered: true
URxvt.visualBell: true
URxvt.background: black
URxvt.foreground: white
URxvt.cursorColor: gray
URxvt.underlineColor: gray
URxvt*keysym.Home: \033[1~
URxvt*keysym.End: \033[4~
URxvt*keysym.Del: \033[3~
URxvt.font:xft:Bitstream Vera Sans Mono:pixelsize=12:antialias=true
URxvt.perl-ext-common: default,matcher
URxvt.urlLauncher: /usr/bin/uzbl-browser
URxvt.matcher.button: 1

+ 830
- 0
.fonts.conf View File

@@ -0,0 +1,830 @@
<?xml version="1.0"?>
<!DOCTYPE fontconfig SYSTEM "fonts.dtd">
<fontconfig>


<!-- Info:
Latest version: http://forums.gentoo.org/viewtopic-p-6183606.html#6183606
xeffects thread: http://forums.gentoo.org/viewtopic-t-511382.html
Alternative: https://wiki.ubuntu.com/Fonts
http://wiki.archlinux.org/index.php/XOrg_Font_Configuration
http://antigrain.com/research/font_rasterization/index.html
http://freddie.witherden.org/pages/font-rasterisation/
http://fontconfig.org/fontconfig-user.html
Free fonts: http://www.design-by-izo.com/2010/06/07/8-excellent-fonts-for-screen-and-print/
-->


<alias>
<family>Times</family>
<prefer>
<family>Times New Roman</family>
<family>Times New Roman PS</family>
<family>Times Ten</family>
<family>Cambria</family>
</prefer>
</alias>


<!-- http://bugs.gentoo.org/show_bug.cgi?id=130466
Times: http://en.wikipedia.org/wiki/Times_Roman
Linux Libertine from http://sourceforge.net/projects/linuxlibertine/
Is important to have good, easily-readable default fonts for:
serif, sans-serif, monospace, Courier -->
<alias>
<family>serif</family>
<prefer>
<family>DejaVu Serif</family>
<family>Bitstream Vera Serif</family>
<family>Liberation Serif</family>
<family>Linux Libertine</family>
<family>Times New Roman</family>
<family>Cambria</family>
</prefer>
</alias>

<!-- Corbel is ugly - don't use -->
<alias>
<family>sans-serif</family>
<prefer>
<family>DejaVu Sans</family>
<family>Bitstream Vera Sans</family>
<family>Verdana</family>
<family>Liberation Sans</family>
</prefer>
</alias>

<!-- Examples: http://www.codestyle.org/css/font-family/sampler-Monospace.shtml
Used to show text email messages in Evolution, by default.
DejaVu Sans Mono is still the best. -->
<alias>
<family>monospace</family>
<prefer>
<family>Bitstream Vera Sans Mono</family>
<family>DejaVu Sans Mono</family>
<family>Nimbus Mono L</family>
<family>Consolas</family>
<family>Lucida Sans Typewriter</family>
<family>Liberation Mono</family>
<family>Andale Mono</family>
</prefer>
</alias>

<!-- Common web font -->
<match target="pattern">
<test name="family">
<string>Helvetica</string>
</test>
<edit name="family" mode="prepend" binding="strong">
<string>Helvetica World</string>
</edit>
</match>


<!-- Replace Arial bold with a better-looking font - looks terrible at e.g. http://digg.com
Calibri is quite good.
ChaletBookTT is awful, found from http://www.identifont.com/
Also try "Arial Unicode MS" or "Arial MT": http://en.wikipedia.org/wiki/Arial_Unicode
Arial MT looks vertically squashed.
Aeriel from http://aur.archlinux.org/packages.php?ID=21892
i.e. ftp://ftp.fi.debian.org/pub/gentoo/distfiles/ttf-arkpandora-2.04.tgz
Liberation fontset: https://fedorahosted.org/releases/l/i/liberation-fonts/
PT Sans: http://www.paratype.com/public/ and http://www.fontstock.com/public/PTSans.zip
CartoGothic Std: http://www.fontsquirrel.com/fonts/download/CartoGothic-Std -->
<match target="pattern">
<test name="family">
<string>Arial</string>
</test>
<test compare="less" name="pixelsize">
<double>12</double>
</test>
<edit name="family" mode="prepend" binding="strong">
<string>CartoGothic Std</string>
</edit>
</match>

<!-- Corbel and Candara are weird-looking, with dropped digits.
Grotesque MT is too wide.
PT Sans: http://www.paratype.com/public/ and http://www.fontstock.com/public/PTSans.zip -->
<match target="pattern">
<test name="family">
<string>Arial</string>
</test>
<test compare="less" name="pixelsize">
<double>18</double>
</test>
<test name="weight" compare="more">
<const>medium</const>
</test>
<edit name="family" mode="prepend" binding="strong">
<string>PT Sans</string>
</edit>
</match>


<!-- Prevent middle stroke of e from being raised too high -->
<match target="pattern">
<test name="family">
<string>Times New Roman PS</string>
</test>
<test compare="less" name="pixelsize">
<double>18</double>
</test>
<edit name="family" mode="prepend" binding="strong">
<string>Times New Roman</string>
</edit>
</match>


<!-- From:
http://repos.archlinux.org/wsvn/packages/fontconfig/trunk/
http://bugs.archlinux.org/task/15833
http://bugs.freedesktop.org/show_bug.cgi?id=18002
http://freedesktop.org/wiki/Software/poppler
http://bugs.gentoo.org/show_bug.cgi?id=303591

Get urw-fonts from http://koji.fedoraproject.org/koji/packageinfo?packageID=905 -->
<match target="pattern">
<test name="family">
<string>ZapfDingbats</string>
</test>
<edit name="family" mode="prepend" binding="same">
<string>Dingbats</string>
</edit>
</match>

<!-- Based on http://bugs.gentoo.org/show_bug.cgi?id=282151 -->
<match target="pattern">
<test name="family">
<string>NewCenturySchlbk</string>
</test>
<edit name="family" mode="append" binding="same">
<string>Century Schoolbook L</string>
</edit>
</match>

<match target="pattern">
<test name="family">
<string>AvantGarde</string>
</test>
<edit name="family" mode="append" binding="same">
<string>URW Gothic L</string>
</edit>
</match>


<match target="pattern">
<test name="family">
<string>ZapfChancery</string>
</test>
<edit name="family" mode="append" binding="same">
<string>URW Chancery L</string>
</edit>
</match>


<!-- From suse-pre-user.conf in fontconfig-2.8.0-20.1.src.rpm from http://software.opensuse.org/search?baseproject=openSUSE%3AFactory&p=1&q=fontconfig
http://bugs.gentoo.org/show_bug.cgi?id=303591
https://bugs.freedesktop.org/show_bug.cgi?id=27653 -->
<match target="pattern">
<test name="family">
<string>symbol</string>
</test>
<edit name="family" mode="append" binding="strong">
<string>OpenSymbol</string>
</edit>
<edit name="family" mode="append" binding="strong">
<string>Standard Symbols L</string>
</edit>
</match>


<match target="pattern" name="family">
<test name="family" qual="any">
<string>fixed</string>
</test>
<edit name="family" mode="assign">
<string>monospace</string>
</edit>
</match>


<!--
From suse-pre-user.conf in fontconfig-2.8.0-2.7.src.rpm from http://download.opensuse.org/factory/repo/src-oss/suse/src/
OpenSUSE Bugzilla #52167 and bugzilla #246804:
Some fonts like "Luxi Mono", and "Nimbus Mono L"
which are intended to be monospace are not detected as
monospace because they have a few glyphs with wrong width.
That is of course a bug in the fonts but this is difficult
to fix and sometimes even impossible because of license reasons.
For most purposes it is useful to force these fonts to be
detected as monospace because it doesn't matter much if only
a handful of rarely used glyphs has the wrong width.
-->
<match target="scan" >
<test compare="contains" name="family">
<string>Luxi Mono</string>
<string>Nimbus Mono L</string>
</test>
<edit mode="assign_replace" name="spacing">
<const>mono</const>
</edit>
</match>


<!-- From http://svn.mandriva.com/cgi-bin/viewvc.cgi/packages/cooker/fontconfig/current/SOURCES/20-mdv-CJK-dualwidth.conf?view=markup
and http://svn.mandriva.com/cgi-bin/viewvc.cgi/packages/cooker/fontconfig/current/SOURCES/25-mdv-CJK-disable-hinting.conf?view=log
https://bugs.freedesktop.org/show_bug.cgi?id=17267
We can't hint CJK fonts well, so turn off hinting for CJK fonts.
Some Asian fonts misadvertise themselves as monospaced when
in fact they are dual-spaced (half and full). This makes
FreeType very confused as it forces all widths to match.
Undo this magic by disabling the width-forcing code.
-->
<match target="font">
<test target="pattern" name="lang" compare="contains">
<string>zh-tw</string>
<string>zh-cn</string>
<string>ja</string>
<string>ko</string>
</test>
<edit name="spacing">
<const>proportional</const>
</edit>
<edit name="globaladvance">
<bool>false</bool>
</edit>
<edit name="hinting" mode="assign">
<bool>false</bool>
</edit>
</match>


<!-- Reject bitmap fonts in favour of Truetype, Postscript, etc. -->
<selectfont>
<rejectfont>
<pattern>
<patelt name="scalable">
<bool>false</bool>
</patelt>
</pattern>
</rejectfont>
</selectfont>


<!-- http://svn.mandriva.com/cgi-bin/viewvc.cgi/packages/cooker/fontconfig/current/SOURCES/26-mdv-no-embeddedbitmap.conf?view=markup
Japanese fonts: http://bbs.archlinux.org/viewtopic.php?id=91276
Calibri font: http://forums.fedoraforum.org/showthread.php?p=1045807#post1045807
Don't use bitmaps at all, because they look horrible. Enable them for individiual fonts and sizes, if needed. -->
<match target="font">
<edit name="embeddedbitmap" mode="assign">
<bool>false</bool>
</edit>
</match>

<!-- This is only here in case it is useful sometime.
Example at http://www.codestyle.org/css/font-family/sampler-Monospace.shtml
Others from 25-no-bitmap-fedora.conf at:
http://distro.ibiblio.org/pub/linux/distributions/texstar/pclinuxos/apt/pclinuxos/2010/SRPMS.main/fontconfig-2.8.0-1pclos2010.src.rpm
<match target="font">
<test name="family" qual="any">
<string>Cambria</string>
<string>Monaco</string>
<string>Kochi Mincho</string>
<string>Kochi Gothic</string>
<string>Sazanami Mincho</string>
<string>Sazanami Gothic</string>
</test>
<edit name="embeddedbitmap" mode="assign">
<bool>false</bool>
</edit>
</match> -->


<!-- Ubuntu options: lcdnone, lcddefault, lcdlight, lcdlegacy -->
<!-- hintnone, hintslight, hintmedium, hintfull -->
<!-- autohint off: https://bugs.launchpad.net/ubuntu/+source/fontconfig/+bug/14310/comments/14 -->
<!-- Blurry fonts: Try rgb, bgr, vrgb, vbgr for "rgba" -->
<!-- Blurry: http://forums.gentoo.org/viewtopic-p-5060979.html#5060979 -->
<match target="font">
<edit name="rgba" mode="assign"><const>rgb</const></edit>
<edit name="autohint" mode="assign"><bool>false</bool></edit>
<edit name="antialias" mode="assign"><bool>true</bool></edit>
<edit name="hinting" mode="assign"><bool>true</bool></edit>
<edit name="hintstyle" mode="assign"><const>hintmedium</const></edit>
<edit name="lcdfilter" mode="assign"><const>lcddefault</const></edit>
</match>


<!-- Microsoft fonts, from http://bbs.archlinux.org/viewtopic.php?pid=728521 -->
<match target="font">
<test compare="eq" name="foundry">
<string>microsoft</string>
</test>
<edit name="hintstyle" mode="assign">
<const>hintfull</const>
</edit>
</match>


<!-- Greyscale for small fonts - not used
<match target="font">
<test name="pixelsize" compare="less_eq"><double>7</double></test>
<edit name="rgba"><const>none</const></edit>
</match>
-->


<!-- lcdlegacy.
Georgia bold & small: http://www.timesonline.co.uk/tol/news/
DejaVu Sans bold & small: http://foo-projects.org/git/?p=lunar/moonbase.git;a=shortlog -->
<match target="font">
<test name="family" qual="any">
<string>Courier</string>
<string>Courier New</string>
<string>DejaVu Sans</string>
<string>FreeSerif</string>
<string>Georgia</string>
<string>Helvetica</string>
<string>Nimbus Roman No9 L</string>
<string>Times New Roman</string>
</test>
<edit name="lcdfilter" mode="assign">
<const>lcdlegacy</const>
</edit>
</match>


<!-- lcdlight.
Lucida Grande at http://www.infoworld.com/d/adventures-in-it/it-personality-types-8-profiles-in-geekdom-313 -->
<match target="font">
<test name="family" qual="any">
<string>Aller</string>
<string>Lucida Grande</string>
<string>Helvetica World</string>
</test>
<edit name="lcdfilter" mode="assign">
<const>lcdlight</const>
</edit>
</match>


<!-- hintslight.
Baskerville: "Leave A Comment" at http://www.jamiesinz.com/2008/08/huay-tung-tao-reservoir/
Consolas: http://www.fedoraforum.org/forum/showthread.php?t=186789&page=7
Corbel and Constantia look far too bold, if not hintslight.
Times New Roman: http://www.billiardworld.com/glossary.html
Luxi Sans bold needs hintslight at http://market-ticker.denninger.net/ -->
<match target="font">
<test name="family" qual="any">
<string>Albany Std</string>
<string>Arial MT</string>
<string>Arial MT Std</string>
<string>Arial Special G1</string>
<string>Arial Unicode MS</string>
<string>Baskerville</string>
<string>CartoGothic Std</string>
<string>Comic Sans MS</string>
<string>Consolas</string>
<string>Constantia</string>
<string>Corbel</string>
<string>Helvetica World</string>
<string>Inconsolata</string>
<string>Luxi Sans</string>
<string>Nimbus Sans L</string>
<string>PT Sans</string>
<string>Sansation</string>
<string>Times New Roman</string>
<string>URW Palladio L</string>
</test>
<edit mode="assign" name="hintstyle">
<const>hintslight</const>
</edit>
</match>


<!-- hintfull
DejaVu Sans looks less fuzzy with hintfull, e.g. buttons at http://ultimateedition.info/ -->
<match target="font">
<test name="family" qual="any">
<string>Andale Mono</string>
<string>Arial</string>
<string>Arial Rounded MT Bold</string>
<string>DejaVu Sans</string>
<string>Impact</string>
<string>Liberation Mono</string>
<string>Liberation Sans</string>
<string>Liberation Serif</string>
<string>Linux Libertine</string>
<string>Microsoft SansSerif</string>
<string>MS Mincho</string>
<string>Vegur</string>
</test>
<edit mode="assign" name="hintstyle">
<const>hintfull</const>
</edit>
</match>


<!-- hintnone.
Arial Black bold: "e" is filled in, if not hintnone - http://www.gamesradar.com/pc/bejeweled-2-deluxe/news/opinion-man-beats-bejeweled-2-after-three-years-was-it-worth-it/a-2010043014175972070/g-2005120714414257238769 -->
<match target="font">
<test name="family" qual="any">
<string>Arial Black</string>
</test>
<test compare="less" name="pixelsize">
<double>50</double>
</test>
<edit mode="assign" name="hintstyle">
<const>hintnone</const>
</edit>
</match>


<!-- autohint.
Luxi Sans - http://market-ticker.denninger.net/
Some entries copied from http://www.infinality.net/blog/?p=10
Arial Black: http://www.wired.com/ -->
<match target="font">
<test name="family" qual="any">
<string>Arial Narrow</string>
<string>Bitstream Vera Serif</string>
<string>Courier10 BT</string>
<string>DejaVu LGC Sans Mono</string>
<string>DejaVu Sans Mono</string>
<string>DejaVu Serif</string>
<string>Delicious</string>
<string>District</string>
<string>Dutch801 Rm BT</string>
<string>Fontin Sans</string>
<string>FreeMono</string>
<string>FreeSans</string>
<string>FreeSerif</string>
<string>Gotham Book</string>
<string>Gotham Light</string>
<string>Gotham Medium</string>
<string>Helvetica</string>
<string>Helvetica LT Std</string>
<string>Lacuna</string>
<string>Lucida Console</string>
<string>Lucida Grande</string>
<string>Lucida Sans Unicode</string>
<string>Luxi Sans</string>
<string>Luxi Serif</string>
<string>MankSans</string>
<string>Metabook-Roman</string>
<string>MetaMedium-Roman</string>
<string>Miriam</string>
<string>Miso</string>
<string>MS Mincho</string>
<string>Myriad Pro</string>
<string>Myriad Web Pro</string>
<string>Nimbus Mono L</string>
<string>Nina</string>
<string>Ocean Sans Std</string>
<string>Swansea</string>
<string>Swiss721</string>
<string>Utopia</string>
<string>Vegur</string>
<string>Verdimka</string>
</test>
<edit name="autohint" mode="assign">
<bool>true</bool>
</edit>
</match>


<!-- From http://forums.gentoo.org/viewtopic-t-511382-start-650.html
To create difference between small Candara and small Candara bold -->
<match target="font">
<test name="family" qual="any">
<string>Candara</string>
</test>
<test compare="less_eq" name="size">
<double>10</double>
</test>
<test name="weight" compare="more">
<const>medium</const>
</test>
<edit name="embolden" mode="assign">
<bool>true</bool>
</edit>
</match>


<!-- From http://bugs.gentoo.org/show_bug.cgi?id=233729 -->
<match target="font">
<test name="family" qual="any">
<string>Andale Mono</string>
<string>Arial</string>
<string>Comic Sans MS</string>
<string>Georgia</string>
<string>Trebuchet MS</string>
<string>Verdana</string>
</test>
<test compare="less" name="weight">
<const>medium</const>
</test>
<test compare="less_eq" name="pixelsize">
<double>7</double>
</test>
<edit mode="assign" name="antialias">
<bool>false</bool>
</edit>
</match>


<!-- Tweak Arial bold at http://www.linux-gamers.net/
Because the top of f is cut off with hintfull and hintmedium.
But don't change the smaller Arial Bold at http://www.telegraph.co.uk/
hintnone is better than hintslight for letter-spacing of headings at http://www.linuxmint.com/blog/ -->
<match target="font">
<test compare="eq" name="family">
<string>Arial</string>
</test>
<test compare="more" name="weight">
<const>medium</const>
</test>
<edit mode="assign" name="hintstyle">
<const>hintmedium</const>
</edit>
<edit name="lcdfilter" mode="assign">
<const>lcdlight</const>
</edit>
<test compare="more_eq" name="pixelsize">
<double>14</double>
</test>
<test compare="less_eq" name="pixelsize">
<double>18</double>
</test>
<edit mode="assign" name="hintstyle">
<const>hintnone</const>
</edit>
</match>


<!-- Tweak Nimbus Sans L at:
http://unity3d.com/company/news/unity2.6-press.html - the sub-headings -->
<match target="font">
<test compare="eq" name="family">
<string>Nimbus Sans L</string>
</test>
<test compare="more" name="weight">
<const>medium</const>
</test>
<test compare="less_eq" name="pixelsize">
<double>14</double>
</test>
<edit mode="assign" name="hintstyle">
<const>hintnone</const>
</edit>
</match>


<!--
From dejavu-fonts in Fedora
http://koji.fedoraproject.org/koji/packageinfo?packageID=1581

/etc/fonts/conf.d/20-unhint-small-dejavu-serif.conf

Disable hinting manually at smaller sizes (< 8ppem)
This is a copy of the Bistream Vera fonts fonts rule, as DejaVu is
derived from Vera.

The Bistream Vera fonts have GASP entries suggesting that hinting be
disabled below 8 ppem, but FreeType ignores those, preferring to use
the data found in the instructed hints. The initial Vera release
didn't include the right instructions in the 'prep' table.

Also good rule for Liberation Sans.
-->
<match target="font">
<test name="family" qual="any">
<string>DejaVu Serif</string>
<string>Liberation Sans</string>
</test>
<test compare="less" name="pixelsize">
<double>7.5</double>
</test>
<edit mode="assign" name="hinting">
<bool>false</bool>
</edit>
</match>


<!-- Prevent middle stroke of e from being raised too high -->
<match target="font">
<test name="family" qual="any">
<string>Times New Roman PS</string>
</test>
<test compare="less" name="pixelsize">
<double>18</double>
</test>
<edit mode="assign" name="hinting">
<bool>false</bool>
</edit>
<edit name="lcdfilter" mode="assign">
<const>lcdnone</const>
</edit>
</match>


<!-- Tweak Lucida Sans normal, for http://www.billiardworld.com/talestip.htm -->
<match target="font">
<test compare="eq" name="family">
<string>Lucida Sans</string>
</test>
<test compare="less_eq" name="weight">
<const>medium</const>
</test>
<edit mode="assign" name="hintstyle">
<const>hintslight</const>
</edit>
<edit name="lcdfilter" mode="assign">
<const>lcdlight</const>
</edit>
</match>


<!-- Tweak PT Sans bold at:
http://www.theaustralian.com.au/news/opinion/one-mans-burden-to-rebuild-shattered-trust/story-e6frg6zo-1225887289935 - the G in BANGKOK -->
<match target="font">
<test compare="eq" name="family">
<string>PT Sans</string>
</test>
<test compare="more_eq" name="weight">
<const>medium</const>
</test>
<test compare="more_eq" name="pixelsize">
<double>14</double>
</test>
<edit mode="assign" name="hintstyle">
<const>hintfull</const>
</edit>
</match>


<!-- Tweak Lucida Grande bold at:
http://market-ticker.denninger.net/ -->
<match target="font">
<test compare="eq" name="family">
<string>Lucida Grande</string>
</test>
<test compare="more_eq" name="weight">
<const>medium</const>
</test>
<edit mode="assign" name="autohint">
<bool>false</bool>
</edit>
</match>


<!--
"y" looks bad (top-left stroke is chopped in its middle),
when small-ish and italic, with hintmedium and hintfull.
E.g. http://www.google.com/search?hl=en&as_q=wine+setthreadpriority+patch&as_epq=1.1.41
Also, space between letters is too narrow, with hintmedium and hintfull:
http://www.zerohedge.com/article/greece-willwill-not-issue-6-debt-week-even-evans-pritchard-summarizes-it-best-greece-drownin
-->
<match target="font">
<test name="slant" compare="more_eq">
<int>80</int>
</test>
<test compare="less_eq" name="pixelsize">
<double>16</double>
</test>
<test name="hintstyle" compare="more_eq">
<const>hintmedium</const>
</test>
<edit mode="assign" name="hintstyle">
<const>hintslight</const>
</edit>
</match>

<!-- Override above rule for Arial italic - "y" still gets chopped at
http://planet.gentoo.org/universe/ - must set autohint on to fix that. -->
<match target="font">
<test compare="eq" name="family">
<string>Arial</string>
</test>
<test name="slant" compare="more_eq">
<int>80</int>
</test>
<test compare="less_eq" name="pixelsize">
<double>16</double>
</test>
<edit mode="assign" name="hintstyle">
<const>hintmedium</const>
</edit>
<edit name="lcdfilter" mode="assign">
<const>lcddefault</const>
</edit>
<edit mode="assign" name="autohint">
<bool>true</bool>
</edit>
</match>


<!-- Bold small fonts can look smudged - hintfull is best, surprisingly.
This is the general rule, for small bold fonts.
E.g. http://www.infoworld.com/d/adventures-in-it/it-personality-types-8-profiles-in-geekdom-313
demibold at http://bugs.archlinux.org/index/proj1 and
http://foo-projects.org/git/?p=lunar/moonbase.git;a=shortlog -->
<match target="font">
<test compare="less_eq" name="pixelsize">
<double>12</double>
</test>
<test name="weight" compare="more">
<const>medium</const>
</test>
<edit mode="assign" name="hintstyle">
<const>hintfull</const>
</edit>
<edit name="lcdfilter" mode="assign">
<const>lcdlegacy</const>
</edit>
<test name="weight" compare="more">
<const>demibold</const>
</test>
<edit name="lcdfilter" mode="assign">
<const>lcdlight</const>
</edit>
</match>


<!-- Tweak Lucida Sans bold, after the general rule, for http://www.billiardworld.com/talestip.htm -->
<!-- Tweak URW Palladio L, after the general rule, for http://blog.gmane.org/gmane.linux.alsa.user/month=20070901 -->
<match target="font">
<test name="family" qual="any">
<string>Lucida Sans</string>
<string>URW Palladio L</string>
</test>
<test compare="more" name="weight">
<const>medium</const>
</test>
<edit mode="assign" name="hintstyle">
<const>hintslight</const>
</edit>
<edit name="lcdfilter" mode="assign">
<const>lcddefault</const>
</edit>
</match>


<!-- Arial bold & small needs hinting disabled.
Worst example: http://www.digg.com/ -->
<match target="font">
<test compare="eq" name="family">
<string>Arial</string>
</test>
<test compare="less_eq" name="pixelsize">
<double>10</double>
</test>
<test name="weight" compare="more">
<const>normal</const>
</test>
<edit name="antialias" mode="assign">
<bool>false</bool>
</edit>
<edit name="rgba">
<const>none</const>
</edit>
<edit name="lcdfilter" mode="assign">
<const>lcdnone</const>
</edit>
<edit mode="assign" name="hintstyle">
<const>hintslight</const>
</edit>
</match>


<!-- Disable autohint for very bold fonts, to stop them looking too bold. -->
<match target="font">
<test name="weight" compare="more">
<const>demibold</const>
</test>
<edit name="autohint" mode="assign">
<bool>false</bool>
</edit>
</match>


<!-- Tweak Luxi Sans bold & small
http://market-ticker.denninger.net/ - sidebar -->
<match target="font">
<test compare="eq" name="family">
<string>Luxi Sans</string>
</test>
<test compare="less_eq" name="pixelsize">
<double>12</double>
</test>
<test name="weight" compare="more">
<const>normal</const>
</test>
<edit mode="assign" name="hintstyle">
<const>hintslight</const>
</edit>
</match>


</fontconfig>

+ 6501
- 0
.local/share/uzbl/adblock
File diff suppressed because it is too large
View File


+ 84
- 0
.local/share/uzbl/adblock.py View File

@@ -0,0 +1,84 @@
#! /usr/bin/env python

import os
from sys import argv
from urlparse import urlparse

def xdghome(key, default):
'''Attempts to use the environ XDG_*_HOME paths if they exist otherwise
use $HOME and the default path.'''

xdgkey = "XDG_%s_HOME" % key
if xdgkey in os.environ.keys() and os.environ[xdgkey]:
return os.environ[xdgkey]

return os.path.join(os.environ['HOME'], default)

# Setup xdg paths.
DATA_DIR = os.path.join(xdghome('DATA', '.local/share/'), 'uzbl/')

# Blockfile location.
BLOCKFILE = os.path.join(DATA_DIR, 'adblock')

JAVASCRIPT = ' '.join(filter(None, map(str.strip, '''
var uzblAdBlock = function() {
var toblock = %s;
for(var n = 0; n < toblock.length; n++) {
var items;
while (1) {
try {
items = document.evaluate(toblock[n], document, null, XPathResult.ORDERED_NODE_ITERATOR_TYPE, null);
if (items == null) { break; }
var i = items.iterateNext();
if (i == null) { break; }
i.parentNode.removeChild(i);
} catch (e) {
break;
}
}
}
};
'''.split('\n'))))


def get_domain(url):
'''Return domain segment of url.'''

if not url.startswith('http'):
url = "http://%s" % url

loc = urlparse(url).netloc
if loc.startswith('www.'):
loc = loc[4:]

return loc


def adblock(url, fifo):
fh = open(BLOCKFILE, 'r')
lines = [line.strip() for line in fh.readlines()]
fh.close()

rules, capture = [], False
for l in lines:
if not l: # newline splits section
capture = False

elif l[0] == '#':
continue

elif capture:
rules.append(l)

elif l[-1] == ':':
if get_domain(l[:-1]) == url or l[:-1] == "global":
capture = True

rulestr = repr(rules).replace("@", "\@")
js = "js %s\n" % (JAVASCRIPT % rulestr)
fh = open(fifo, "w")
fh.write(js)
fh.close()

if __name__ == '__main__':
adblock(get_domain(argv[6]), argv[4])

+ 3
- 0
.local/share/uzbl/bookmarks View File

@@ -0,0 +1,3 @@
http://aur.archlinux.org/packages.php?ID=34554&detail=1 archlinux
http://www.uzbl.org/ uzbl
http://www.google.com/ig google

+ 1
- 0
.local/share/uzbl/delicious_bookmark.js View File

@@ -0,0 +1 @@
(function(){f='http://delicious.com/save?url='+encodeURIComponent(window.location.href)+'&title='+encodeURIComponent(document.title)+'&v=5&';a=function(){if(!window.open(f+'noui=1&jump=doclose','deliciousuiv5','location=yes,links=no,scrollbars=no,toolbar=no,width=550,height=550'))location.href=f+'jump=yes'};if(/Firefox/.test(navigator.userAgent)){setTimeout(a,0)}else{a()}})()

+ 134
- 0
.local/share/uzbl/dl-progress.sh View File

@@ -0,0 +1,134 @@
#!/bin/bash
#
# the original dget.sh script:
# (c) 2007 by Robert Manea
#
# bashtardized and heavily modded for uzbl:
# 2009 by pbrisbin
#
# requires:
# dzen2
# gdbar
# wget
# xwininfo
# wmctrl (for now)
#
###

# dzen
# xft font available with dzen2-svn from aur
#FONT='-xos4-terminus-*-*-*-*-12-*-*-*-*-*-*-*'
FONT='-*-bitstream vera sans mono-*-r-*-*-12-*-*-*-*-*-*-*'
FG='#606060'
BG='#303030'

# gdbar
bar_FG='#909090'
bar_BG='#606060'
bar_H=7
bar_W=150

# the place to download to
DIR="$HOME"

# refresh rate on the progress bar
SECS=1

# this allows for some simple WM-specific adjustments
pad_Y=38
pad_X=2

# these are passed in from uzbl
PID="$2"
XID="$3"
URL="$8"

# auto open the file post-download based on the
# file's extension
# TODO: please people, add your own here and report them on
# the uzbl wiki page. these are the ones i use, i'd love
# to have a more complete list
open() {
case "$1" in
*.pdf) epdfview "$1" & ;;
*.jpg|*.png|*.jpeg) mirage "$1" & ;;
*.txt|*README*|*.pl|*.sh|*.py|*.hs) urxvtc -e vim "$1" & ;;
*.mov|*.avi|*.mpeg|*.mpg|*.flv|*.wmv|*.mp4) mplayer "$1" & ;;
esac
}

# this function returns XY geometry for the spawning uzbl
find_uzbl() {
# x-winid is in the documentation but coming over blank for me
# if it's blank, wmctrl provides a workaround
[ "$XID" = "" ] && XID="$(wmctrl -lp | awk "/$PID/"'{print $1}')"

# someone better with awk could probably parse this all at once
uzbl_X=$(xwininfo -id "$XID" | awk '/Corners/ {print $2}' | cut -d '+' -f 2)
uzbl_Y=$(xwininfo -id "$XID" | awk '/Corners/ {print $2}' | cut -d '+' -f 3)
uzbl_W=$(xwininfo -id "$XID" | awk '/Width/ {print $2}')
uzbl_H=$(xwininfo -id "$XID" | awk '/Height/ {print $2}')

# some math here to place the first progress bar just above
# the uzbl status bar
H=16
W=$uzbl_W
X=$((uzbl_X+pad_X))
Y=$((uzbl_Y+uzbl_H-pad_Y))
}

# file to dump wget progress into and read from
# it needs to be specific to this DL instance
STAT="/tmp/dl_progress.$$"

# this file holds the HW and XY to use for the next
# download instance and must span across each download
LOC="/tmp/dl_location"

# if no other wgets are running, we clear the stored
# location. this is the best way i can determine if
# this is a new 'downloading session' and we need to
# start over at the bottom of the stack
ps -A | grep -q wget || rm -f $LOC

# and if the location file still exists we source it
# to know where to place the next status bar, else
# we find uzbl
[ -f $LOC ] && . $LOC || find_uzbl

# set up the location of the next display
new_Y=$((Y-H))
echo -e "H=$H\nW=$W\nX=$X\nY=$new_Y\n" > $LOC

# get filename from the url and convert some hex codes
# i hate spaces in filenames so i'm switching them
# with underscores here, adjust the first s///g if
# you want to keep the spaces
FILE="$(basename $URL | sed -r \
's/[_%]20/\_/g;s/[_%]22/\"/g;s/[_%]23/\#/g;s/[_%]24/\$/g;
s/[_%]25/\%/g;s/[_%]26/\&/g;s/[_%]28/\(/g;s/[_%]29/\)/g;
s/[_%]2C/\,/g;s/[_%]2D/\-/g;s/[_%]2E/\./g;s/[_%]2F/\//g;
s/[_%]3C/\</g;s/[_%]3D/\=/g;s/[_%]3E/\>/g;s/[_%]3F/\?/g;
s/[_%]40/\@/g;s/[_%]5B/\[/g;s/[_%]5C/\\/g;s/[_%]5D/\]/g;
s/[_%]5E/\^/g;s/[_%]5F/\_/g;s/[_%]60/\`/g;s/[_%]7B/\{/g;
s/[_%]7C/\|/g;s/[_%]7D/\}/g;s/[_%]7E/\~/g;s/[_%]2B/\+/g')"

# download
wget -O "$DIR/$FILE" --user-agent=Firefox "$URL" > $STAT 2>&1 &
pid=$!

# show the dzen notification
(while ps -A | grep -q $pid; do
REM="$(awk '/s$/ {print $NF}' $STAT | tail -n1)"
PROG=$(grep -Eo " [0-9]{1,3}%" $STAT | tail -n1 | sed 's/%$//g')
echo -n " Downloading ${FILE:0:22}... (${REM:-unknown}) "
echo "${PROG:-0} 100" | gdbar -h $bar_H -w $bar_W -fg $bar_FG -bg $bar_BG
sleep "$SECS"
done; echo " Download saved to $DIR/$FILE"; sleep 3) | dzen2 -ta l -w $W -h $H -x $X -y $Y -fg $FG -bg $BG -fn "$FONT" -e "onstart=stick;button3=exec:kill $pid,rm -f $STAT,exit:1"

# finally, auto-open the downloaded file
[ $? -eq 0 ] && open "$DIR/$FILE"

rm -f "$STAT"

exit 0

+ 6240
- 0
.local/share/uzbl/jquery.js
File diff suppressed because it is too large
View File


+ 1
- 0
.local/share/uzbl/readability.js View File

@@ -0,0 +1 @@
(function(){readConvertLinksToFootnotes=false;readStyle='style-apertura';readSize='size-x-large';readMargin='margin-narrow';_readability_script=document.createElement('script');_readability_script.type='text/javascript';_readability_script.src='http://lab.arc90.com/experiments/readability/js/readability.js?x='+(Math.random());document.documentElement.appendChild(_readability_script);_readability_css=document.createElement('link');_readability_css.rel='stylesheet';_readability_css.href='http://lab.arc90.com/experiments/readability/css/readability.css';_readability_css.type='text/css';_readability_css.media='all';document.documentElement.appendChild(_readability_css);_readability_print_css=document.createElement('link');_readability_print_css.rel='stylesheet';_readability_print_css.href='http://lab.arc90.com/experiments/readability/css/readability-print.css';_readability_print_css.media='print';_readability_print_css.type='text/css';document.getElementsByTagName('head')[0].appendChild(_readability_print_css);})();

+ 1
- 1
.vimrc View File

@@ -1,5 +1,5 @@
set nu
set term=xterm
set term=rxvt-unicode
set softtabstop=4
set shiftwidth=4
set expandtab

+ 6
- 0
.weatherrc View File

@@ -0,0 +1,6 @@
[default]
City = Lafayette
St = IN
Forecast = True
ID = KLAF


+ 18
- 0
.xmobarrc View File

@@ -0,0 +1,18 @@
Config { font = "xft:Bitstream Vera Sans Mono:pixelsize=12:antialias=true"
, bgColor = "black"
, fgColor = "grey"
, position = TopW L 100
, commands = [ Run Weather "KLAF" ["-t"," <tempF>F","-L","64","-H","77","--normal","green","--high","red","--low","lightblue"] 36000
, Run Network "wlan0" ["-L","0","-H","32","--normal","green","--high","red"] 10
, Run Cpu ["-L","3","-H","50","--normal","green","--high","red"] 10
, Run Memory ["-t","Mem: <usedratio>%"] 10
, Run Swap [] 10
, Run Battery ["-L","50","-H","75","--high","green","--normal","yellow", "--low", "red"] 10
, Run Date "%a %b %_d %l:%M" "date" 10
, Run StdinReader
]
, sepChar = "%"
, alignSep = "}{"
, template = "%StdinReader% }{ %cpu% | %memory% | %swap% | %wlan0% | %battery% <fc=#ee9a00>%date%</fc> | %KLAF%"
}


+ 19
- 0
.xmonad/xmonad.hs View File

@@ -0,0 +1,19 @@
import XMonad
import XMonad.Hooks.DynamicLog
import XMonad.Hooks.ManageDocks
import XMonad.Util.Run(spawnPipe)
import XMonad.Util.EZConfig(additionalKeys)
import System.IO

main = do
xmproc <- spawnPipe "xmobar"
xmonad $ defaultConfig
{ terminal = "urxvt"
, modMask = mod4Mask
, borderWidth = 2
, layoutHook = avoidStruts $ layoutHook defaultConfig
, logHook = dynamicLogWithPP $ xmobarPP
{ ppOutput = hPutStrLn xmproc
, ppTitle = xmobarColor "green" "" . shorten 50
}
}

+ 33
- 0
.zshrc View File

@@ -0,0 +1,33 @@
alias vi='vim'

fortune ~/fortune-mod-buddhism/buddhism
echo ""

bindkey "^[[1~" beginning-of-line
bindkey "^[[4~" end-of-line
bindkey "^[[3~" delete-char

# Path to your oh-my-zsh configuration.
export ZSH=$HOME/.oh-my-zsh

# Set to the name theme to load.
# Look in ~/.oh-my-zsh/themes/
export ZSH_THEME="geoffgarside"

# Set to this to use case-sensitive completion
# export CASE_SENSITIVE="true"

# Comment this out to disable weekly auto-update checks
# export DISABLE_AUTO_UPDATE="true"

# Uncomment following line if you want to disable colors in ls
# export DISABLE_LS_COLORS="true"

# Which plugins would you like to load? (plugins can be found in ~/.oh-my-zsh/plugins/*)
# Example format: plugins=(rails git textmate ruby lighthouse)
plugins=(git)

source $ZSH/oh-my-zsh.sh

# Customize to your needs...
export PATH=/bin:/usr/bin:/sbin:/usr/sbin:/usr/bin/perlbin/site:/usr/bin/perlbin/vendor:/usr/bin/perlbin/core:/home/james/bin

+ 40
- 0
bin/dvd2avi View File

@@ -0,0 +1,40 @@
#!/bin/sh

# Dvd2Avi 0.2
# Only does one title at a time, but "avimerge" from Transcode
# can sort it from there.

# by yyz

echo -n "Enter the name of output file (without extension):"
read FILE

echo -n "Enter the title you wish to rip:"
read TITLE

echo -n "Select a quality level (h/n/l)[[n]]:"
read Q

if [[ -z $Q ]];then
# If no quality passed, default to normal
Q=n
fi

if [[ $Q = h ]]; then
# If h passed, use high quality
mencoder dvd://$TITLE -slang en -oac mp3lame -lameopts br=320:cbr -ovc lavc -lavcopts vcodec=mpeg4:vhq -vf scale -zoom -xy 800 -o $FILE.avi
exit $?
fi

if [[ $Q = n ]]; then
# If n passed, use normal quality (recommended)
mencoder dvd://$TITLE -alang en -oac mp3lame -lameopts br=160:cbr -ovc lavc -lavcopts vcodec=mpeg4:vhq -vf scale -zoom -xy 640 -o $FILE.avi
exit $?
fi

if [[ $Q = l ]]; then
# If l passed, use low quality. not really worth it,
# hardly any smaller but much crappier
mencoder dvd://$TITLE -alang en -oac mp3lame -lameopts br=96:vbr -ovc lavc -lavcopts vcodec=mpeg4:vhq -vf scale -zoom -xy 320 -o $FILE.avi
exit $?
fi

+ 3
- 0
bin/nethack View File

@@ -0,0 +1,3 @@
#!/bin/sh

urxvt -fn "xft:Bitstream Vera Sans Mono:pixelsize=24;antialias=true" -e telnet nethack.alt.org

+ 3
- 0
bin/urlencode View File

@@ -0,0 +1,3 @@
#!/bin/sh
tags="$@"
echo $tags

Loading…
Cancel
Save