Archive
Start vuze with Java 7
Problem
I installed Oracle Java 7 to /opt/java. When I start vuze and check Help -> About, it says it is still using Java 6. Hmm…
Solution
Edit the vuze launch script:
JAVA_PROGRAM_DIR="/opt/java/bin/" # Add the trailing slash!
Auto Login to Windows 7
Problem
I have a Windows 7 in VirtualBox. When I launch it, I don’t want to spend time with logging in. How to skip this step?
Solution
I found the solution here.
In short: launch netplwiz, in the Users tab, uncheck the box next to “Users must enter a user name and password to use this computer”, press Apply, provide the password, then OK, OK.
Insert syntax highlighted source in Powerpoint
Problem
You want to have syntax highlighted source in Powerpoint.
Solution
First, create an RTF file from the source:
pygmentize -f rtf -o hello.rtf hello.py
Open the RTF file in Word, select the source, then insert it in Powerpoint.
I made a basic script to automate the conversion. Usage:
py2rtf hello.py
The script is available here.
repl.it
“The repl.it project is an attempt to create an online environment for interactively exploring programming languages. It provides a fully-featured terminal emulator and code editor, powered by interpreter engines for more than 15 languages.
All our interpreters are written in (or compiled to) JavaScript, and run completely on the user’s device, regardless or whether it’s a desktop, laptop or phone.” (source)
FAQ here. And yes, they have Python.
Increase the size of a Virtualbox hard drive (.vdi)
The following entry is based on this post.
Problem
I have a Linux host with a Windows 7 guest. The hard disk of the Windows guest was set to 30 GB but it got full. How could I extend its size to 40 GB for instance?
Solution
Locate the .vdi file of the virtual system. To be safe, make a backup copy of it. After that you can increase its size:
sudo VBoxManage modifyhd Windows7.vdi --resize 40000
Here Windows7.vdi is the name of my .vdi file and 40000 is given in megabytes, which is roughly 40 GB.
Now, if you boot the system and you verify the size of the C: drive, it will still be the old value. The increased size appears as a new unformatted and unused partition. You can join it with the C: partition the following way:
Go to the Control Panel, then System and Security, then Administrative Tools. Here you will see an icon called Computer Management. Start it. Choose Disk Management on the left side. Right click on drive C: and choose “extend volume“. It will be extended in a second. Done.
Powerpoint to PDF
I just discovered that Microsoft Powerpoint 2007 supports PDF export. By default this plugin is not installed. Click on the Office button, and under Save as... there will be a menu point about exporting to PDF and XPS. Click on it and you will be redirected to a help file from where you can visit a download page of this export plugin. Once installed, this feature is available under Save as…