<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Screen 13 &#187; Python</title>
	<atom:link href="http://unrealvoodoo.org/hiteck/blog/category/python/feed/" rel="self" type="application/rss+xml" />
	<link>http://unrealvoodoo.org/hiteck/blog</link>
	<description>Just another WordPress weblog</description>
	<lastBuildDate>Fri, 02 Jul 2010 16:20:43 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.8.4</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Pelikoodausta Pythonilla</title>
		<link>http://unrealvoodoo.org/hiteck/blog/2008/11/pelikoodausta-pythonilla/</link>
		<comments>http://unrealvoodoo.org/hiteck/blog/2008/11/pelikoodausta-pythonilla/#comments</comments>
		<pubDate>Tue, 11 Nov 2008 13:41:33 +0000</pubDate>
		<dc:creator>skyostil</dc:creator>
				<category><![CDATA[Python]]></category>
		<category><![CDATA[Releases]]></category>

		<guid isPermaLink="false">http://unrealvoodoo.org/hiteck/blog/uncategorized/pelikoodausta-pythonilla/</guid>
		<description><![CDATA[Kävin tänään kertomassa peliohjelminnista Python-kielellä Oulun yliopiston ohjelmoinnin perusteet -kurssilaisille. Session tuloksena syntyi matopeli, jonka voi ladata alta:

Pelataksesi peliä tarvit Pythonin sekä pyglet-lisäkirjaston. Peli toimii Linuxilla, Windowsilla sekä Mac OS X:llä. Kiitokset Tommille musiikista ja ääniefekteistä.
English translation
Today I gave a presentation on game programming using Python to the students attending Programming 101 at the University [...]]]></description>
			<content:encoded><![CDATA[<p>Kävin tänään kertomassa peliohjelminnista Python-kielellä Oulun yliopiston ohjelmoinnin perusteet -kurssilaisille. Session tuloksena syntyi matopeli, jonka voi ladata alta:</p>
<p><a href="http://muksuluuri.ath.cx/~skyostil/projects/matopeli-1.0.zip"><img src='http://unrealvoodoo.org/hiteck/blog/wp-content/uploads/2008/11/mato1-150x150.png' title='Kuvakaappaus matopelistä' alt='Kuvakaappaus matopelistä' /></a></p>
<p>Pelataksesi peliä tarvit <a href="http://www.python.org">Pythonin</a> sekä <a href="http://www.pyglet.org">pyglet-lisäkirjaston</a>. Peli toimii Linuxilla, Windowsilla sekä Mac OS X:llä. Kiitokset <a href="http://www.scenerychannel.com">Tommille</a> musiikista ja ääniefekteistä.</p>
<h2>English translation</h2>
<p>Today I gave a presentation on game programming using Python to the students attending Programming 101 at the University of Oulu. The result of the session was a classic snake game, which you can download above.</p>
<p>In order to play the game you&#8217;ll need <a href="http://www.python.org">Python</a> and the <a href="http://www.pyglet.org">pyglet-module</a>. The game works on Linux, Windows and Mac OS X. Thanks to <a href="http://www.scenerychannel.com">Tommi</a> for the music and sound effects.</p>
]]></content:encoded>
			<wfw:commentRss>http://unrealvoodoo.org/hiteck/blog/2008/11/pelikoodausta-pythonilla/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
		<item>
		<title>Disable mandatory screen saver</title>
		<link>http://unrealvoodoo.org/hiteck/blog/2005/12/disable-mandatory-screen-saver/</link>
		<comments>http://unrealvoodoo.org/hiteck/blog/2005/12/disable-mandatory-screen-saver/#comments</comments>
		<pubDate>Tue, 13 Dec 2005 12:51:18 +0000</pubDate>
		<dc:creator>skyostil</dc:creator>
				<category><![CDATA[Python]]></category>

		<guid isPermaLink="false">http://unrealvoodoo.org/hiteck/blog/python/disable-mandatory-screen-saver/</guid>
		<description><![CDATA[So you&#8217;re trying to watch a movie on your shiny new corporate laptop. Ten minutes into the film, the automatic screen saver kicks in, locks the machine and forces you to re-login. The little weasels at IT have even disabled the screen saver properties, so you can&#8217;t even turn it off.
Here&#8217;s a tiny python script [...]]]></description>
			<content:encoded><![CDATA[<p>So you&#8217;re trying to watch a movie on your shiny new corporate laptop. Ten minutes into the film, the automatic screen saver kicks in, locks the machine and forces you to re-login. The little weasels at IT have even disabled the screen saver properties, so you can&#8217;t even turn it off.</p>
<p>Here&#8217;s a tiny python script that will fake keyboard activity every five minutes in order to prevent a screen saver from activating.</p>
<pre class="code">
"""Fake keyboard activity to prevent screen
   saver from activating."""
import win32api
import win32con
import time

while True:
	print "Faking keyboard activity at", time.asctime()
	win32api.keybd_event(win32con.VK_SHIFT, 0, 0, 0)
	win32api.keybd_event(win32con.VK_SHIFT, 0, \\
                             win32con.KEYEVENTF_KEYUP, 0)
	time.sleep(60 * 5)
</pre>
<p>Download:</p>
<ul>
<li><a href="/hiteck/projects/misc/disable-screensaver.exe">Compiled program</a></li>
<li><a href="/hiteck/projects/misc/disable-screensaver.py">Python source code</a></li>
<li><a href="/hiteck/projects/misc/disable-screensaver.c">C source code</a></li>
</ul>
]]></content:encoded>
			<wfw:commentRss>http://unrealvoodoo.org/hiteck/blog/2005/12/disable-mandatory-screen-saver/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Stakeout</title>
		<link>http://unrealvoodoo.org/hiteck/blog/2005/01/stakeout/</link>
		<comments>http://unrealvoodoo.org/hiteck/blog/2005/01/stakeout/#comments</comments>
		<pubDate>Wed, 05 Jan 2005 13:01:21 +0000</pubDate>
		<dc:creator>skyostil</dc:creator>
				<category><![CDATA[Python]]></category>
		<category><![CDATA[Utilities]]></category>

		<guid isPermaLink="false">http://unrealvoodoo.org/hiteck/blog/python/stakeout/</guid>
		<description><![CDATA[This program monitors a bunch of files and runs a command when any of them changes.
The idea was pilfered from Pragmatic Automation. This program uses fcntl and thus only works on Unix derivatives.
Here&#8217;s how you might use it:

find -name \*.py &#124; xargs ./stakeout.py src/TestAll.py

Download: Python source, Example shell script
]]></description>
			<content:encoded><![CDATA[<p>This program monitors a bunch of files and runs a command when any of them changes.</p>
<p>The idea was pilfered from <a href="http://www.pragmaticautomation.com/cgi-bin/pragauto.cgi">Pragmatic Automation</a>. This program uses fcntl and thus only works on Unix derivatives.</p>
<p>Here&#8217;s how you might use it:</p>
<pre class="code">
find -name \*.py | xargs ./stakeout.py src/TestAll.py
</pre>
<p>Download: <a href="/hiteck/projects/misc/stakeout.py">Python source</a>, <a href="/hiteck/projects/misc/stakeout">Example shell script</a></p>
]]></content:encoded>
			<wfw:commentRss>http://unrealvoodoo.org/hiteck/blog/2005/01/stakeout/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>pyhtml</title>
		<link>http://unrealvoodoo.org/hiteck/blog/2004/12/pyhtml/</link>
		<comments>http://unrealvoodoo.org/hiteck/blog/2004/12/pyhtml/#comments</comments>
		<pubDate>Sun, 26 Dec 2004 12:58:11 +0000</pubDate>
		<dc:creator>skyostil</dc:creator>
				<category><![CDATA[Python]]></category>
		<category><![CDATA[Utilities]]></category>

		<guid isPermaLink="false">http://unrealvoodoo.org/hiteck/blog/python/pyhtml/</guid>
		<description><![CDATA[PHP-style inline code in Python.
Here&#8217;s a sample html file:

&#60;html&#62;
&#60;body&#62;
The square of 5 is
&#60;?
print 5*5
?&#62;
.
&#60;/body&#62;
&#60;/html&#62;

Note that the opening and closing tags (&#60;? and ?&#62;) must be in separate lines.
Installation for Apache
Add the following to your httpd.conf and copy this script into your
cgi-bin directory:

   AddHandler python-parsed-html .pyhtml
   Action python-parsed-html /cgi-bin/pyhtml.py

Also, make sure you [...]]]></description>
			<content:encoded><![CDATA[<p>PHP-style inline code in Python.</p>
<p>Here&#8217;s a sample html file:</p>
<pre class="code">
&lt;html&gt;
&lt;body&gt;
The square of 5 is
&lt;?
print 5*5
?&gt;
.
&lt;/body&gt;
&lt;/html&gt;
</pre>
<p>Note that the opening and closing tags (&lt;? and ?&gt;) must be in separate lines.</p>
<h2>Installation for Apache</h2>
<p>Add the following to your httpd.conf and copy this script into your<br />
cgi-bin directory:</p>
<pre>
   AddHandler python-parsed-html .pyhtml
   Action python-parsed-html /cgi-bin/pyhtml.py
</pre>
<p>Also, make sure you have the actions modules (mod_actions) loaded or the above won&#8217;t work.</p>
<p>Download: <a href="/hiteck/projects/misc/pyhtml.py">pyhtml.py</a></p>
]]></content:encoded>
			<wfw:commentRss>http://unrealvoodoo.org/hiteck/blog/2004/12/pyhtml/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
