Archive by Author | Darren

ReactOS on VirtualBox: No need for step-by-step instructions

This is so simple there’s no need for step-by-step instructions, but I kept notes so I might as well post them.

ReactOS 4.5 on VirtualBox 4.3.x on Debian 8.x. Not on VB5.1 because the older versions are what the Debian repo provides.

(1) Installed VirtualBox;

$ apt-get install virtualbox dkms 

Host is 32 bit Debian 8.4 Netbook with 1 GB RAM and 250 GB HD. Low spec! (Atom N550)

(2) http://www.reactos.org/download and downloaded both disk images; starting with iso rather than LiveCD. Apparently should be able to use guest additions from Win 32 bit, 2003-era. Unzipped the images.

(3) Ran VB; selected ‘New’.

(a) Put in details — Name, Windows, 32 bit 2003.



(b) 512 MB RAM (default in this case)

(c) 20 GB HD.

(d) VDI format is fine.

(e) Dynamic is fine.

(4) System. Enabled PAE/NX.

(5) Storage — put the Reactos ISO in the virtual drive.

(6) Boot.

(7) Let install run:

(a) Chose language

(b) Pressed enter a bunch of times. I chose to do a full format not a ‘quick’ one.

(c) Waited… … … … … …

(d) Chose default to put OS in C:\ReactOS

(e) Chose default bootloader installation.

(8) Removed cd rom image from virtual drive. (Devices menu).

(9) Rebooted.

(a) Watched as it interrogated the hardware and installed some devices.

(b) Clicked through setup. Admin password.

(10) Rebooted again.

(11) It wanted to install a driver but could not. Oh well.

(12) Devices menu of VB — inserted guest addtions.

(a) Opened explorer in guest and double clicked on additions x86 exe file in the cdrom directory.

(b) Default install.

(c) Rebooted.

(13) Shared folders…

(a) Created a folder on Linux host. Made sure users had read/write permissions.

(b) In VB manager, added that folder in Share Folders menu. Did not click auto mount.

(c) Booted VM.

(d) Double-clicked ‘My netowrk places’ on the ReactOS desktop and there it was, called \\VBOXSVR\vbshare.

(e) In a terminal, needed to assign the folder a drive letter.

(f) Opened command prompt on guest and typed

C:\ net use x: \\VBOXSVR\vbshare

(g) Typed x:

(h) Typed X:\ notepad textfile.txt.

(i) Typed some crap. yep, it’s there.

(j) Looked for the file on host system. Modified it.

(k) Saw modifications in guest and host. OK, that works.

(l) I’m not going to bother automating it, I’ll just put a readme on the ReactoS desktop.

(14) Done, as far as I can see. Looks pretty good.

Having said that, all the applications I wanted to be able to run can run on wine.

Still, seems to work.

Wine.

CAPS LOCK disable on Windows without admin rights

Lots of sites tell you how to disable/remap CapsLock. But what if you don’t have administrator rights? Most of them tell you to pry off the key. Well, instead, I went to:

https://dropline.net/2009/05/mapping-caps-lock-to-control-without-admin-access/

Here is an extract, which I put here just in case the original site vanishes, as sites sometimes do:

There’s a duplicate of the keyboard mapping registry key under HKEY_CURRENT_USER, which non-administrators can modify, and it appears to behave exactly like the key under HKEY_LOCAL_MACHINE.  So, for anyone in a similar position, here’s the registry key to modify:

HKEY_CURRENT_USER→Keyboard Layout→Scancode Map =
hex:00,00,00,00,00,00,00,00,02,00,00,00,1d,00,3a,00,00,00,00,00

You can download a registry update file here.  Save it to your computer, double-click it to update your registry, then reboot and enjoy your vastly-improved keyboard.

Here is a screengrab of the .reg file:

capslock

Worked a treat on Windows 7, but it did not work on Windows 10.

Hmm…Code for conversion of CapsLock to Shift is:

00,00,00,00,00,00,00,00,02,00,00,00,2a,00,3a,00,00,00,00,00

(http://johnhaller.com/useful-stuff/disable-caps-lock)

Codes explained here:

https://www.experts-exchange.com/articles/2155/Keyboard-Remapping-CAPSLOCK-to-Ctrl-and-Beyond.html

But why it does not work in Windows 10 I don’t know. I did try it on a work desktop machine (that’s why I don’t have admin rights, ‘cos it’s a work machine), so perhaps it downloads registry files on logging in? Does that make any sense?

Right now I don’t care enough to find out, but I’ll look into it at some point in the future.

 

So there.

Another Font for a Very Specific Purpose

I have been reading stuff on my HP200LX palmtop using VR, the Vertical Reader.  It basically turns the LX into a pretty useful book reader — ASCII only.  You have a single column of text, rather like a newspaper column. It’s most excellent. It comes with search, bookmark and various customisation facilities.

However, I found the fonts that came with it just a bit too small. I decided to make one of my own, which is at an old post here, but it went too far the other way and is too wide. So I decided to take that font and narrow it a bit — make a condensed version, in the correct parlance. Thus:

The two fonts are shown below. The comments about the design philosophy in the earlier post remain valid; but the new one is I think just as readable and gets quite a bit more text on the screen.

‘djgtry2.vfn’

Using the font 'djgthin.vfn'.

Using the font ‘djgthin.vfn’.

The new font is available at DSPACE, along with the earlier one. The file to download is DJGTHIN.VFN.zip.

For what it is worth.

Scones using only 2.5 ingedients

This recipe courtesy of Kylie Evans at Biotext. May need to try it a few times to get the knack.

First, preheat oven to about 200oC and line a couple of baking trays with paper.

Work fast.

You will need:

o some volume of self-raising flour (a couple of cups)

o half that volume of thickened cream.

Combine flour and cream in a bowl, mixing with a bread and butter knife until combined. The less mixing the better.

The half an ingredient: If any dry material is left (say as crumbs in the bottom of the bowl) use a little milk just to add liquid. Mixture should not be sticky.

Use your hands to press out the dough into slabs about an inch thick. Use a cutter (about 1.5 inches across) to cut out the scones.

Bake for 10 minutes, maybe 12.

Mmmmm.

Impressions of wine

Wine is a mighty thing. Wine is a project to allow Linux (and Mac OS) users to run Windows programs.  It does not emulate a Windows machine, the way, for example, DOSBox emulates the hardware that DOS runs on or that VirtualBox (VB) does on a much larger and more complex scale.  It is more like an interpreter. The website calls it a ‘compatibility layer’. What that means for us non-experts, is it takes Windows’ instructions to the hardware and translates them into Unix equivalents, then passes them on. This is a less flexible approach than simulating hardware (it is specific for Windows, for example, where a VM can run any number of operating systems) but it is much faster and allows excellent seamless integration with the Linux environment.

I have used Wine on and off for years, but I am not a regular user. I use VB to run a Windows 7 VM on my main workstation, because I have to work with people who use Microsoft Office and various add-ins like MathType, and at the time when I set the VM up it was probably the best solution.

I’m not so sure now.

I have an old CD of MS Office 97. I recall trying to install it under Wine a few years back, and it was not highly satisfactory. Word threw some funny errors, and I could not type into Excel. But that was a few years back, and I use Debian on my desktop, which is not renowned for using the latest versions of packages.

So I thought I’d try it again.

I have a Netbook running current Debian, which is a lot newer than the ‘old stable’ I have on my workstation. I have a USB CD drive, so I gave it a lash.

Brilliant.

Plugged in the CD drive. It appeared in the file manager. [Caja — I use MATE, which I think is a great example of a FOSS project. Dissatisfaction with where the Gnome desktop was going (when it switched from Gnome 2 to Gnome 3) prompted people to get together to continue to refine Gnome 2. The result is a desktop environment which is very congenial for us slightly older users who first saw a GUI in the 1990s and reacted violently when Microsoft introduced the ribbon, for example. Now users can choose between Gnome and MATE, and everyone has more options.] I then opened a terminal and went to the CDROM subdirectory (in this case, at /media/cdrom) and ran:

/media/cdrom $ wine autorun.exe

or whatever the installation program was called. Wine opened it like a native Linux application, installed the program (the psuedo-Windows hard drive is hidden away in .wine/drive_c of the user’s home directory).

It appeared in the ‘Other’ menu under the MATE Applications menu. So did a bunch of other stuff; it seemed to generate menu entries for all sorts of Windows executables that I did not want to use.

But that’s OK. Installed and ran Mozo, the MATE menu editor, and turned off all the entries I didn’t want, and moved Word and Excel to the Office category, and bingo I have Word and Excel (97, admittedly) running like native applications, almost no effort required.

Found an old zip file of Rietica1.7.7 (32 bit) on my hard drive; that installed perfectly as well. The Rietica website only hosts the new 64 bit version; I’ve not tried that.

 

Don’t know if I’ll even use Word and Excel, but the jump in the quality of the experience compared to Wine a few years ago shows how it’s a vibrant, massively useful project. A great solution.

 

Older tech.

Journal self-archiving policies

One of the most-viewed pages here (it’s all relative; still not very many hits really) is the list of dodgy publishers. It’s a drop in the ocean, but it gets a few hits. Something else I’d like to bring all into one place, even though it’s been done elsewhere, is to summarise self-archiving polices. I’ll focus on the journals I’ve published in, preparatory to putting together a web archive of all my papers that I am allowed to self-archive (on my website and maybe on ResearchGate). It’s really just a resource for me, but I might as well make it public.

Some journals are open access; you don’t need to self-archive those, but usually you can.

Some allow you to archive a proper reprint, processed and edited by the journal — like the IUCr, as shown below.

Some suggest you archive the ‘author’s final version’ but don’t want you to put up anything with the journal’s imprimatur.

Some say ‘mine mine mine’ and don’t let you host it at all. I hope to make this clear.

The page lives at https://darrengoossens.wordpress.com/journal-self-archiving-policies, and so far has exactly one (1) entry, the good old IUCr, which has a very enlightened policy. They allow self-archiving as long as you use the official e-reprint, rather than just the downloaded PDF, and they request that you provide a link to the journal. Seems very reasonable. The official e-reprint is easy to recognise; it has a distinctive front page with some official words on it, something like this (colours may vary):

Front page of IUCr reprint, showing it is dfferent from download from journal.

Note the box with the notice near the bottom of the page.

 

I think their policy is very reasonable because the IUCr has a very professional publication and editorial team who need to be paid and ought to be paid. Subscriptions are part of the mix, yet they allow authors to house their own work and to distribute copies to colleagues freely. It seems a very sensible mix.

More updates as they come to hand.

Add LibreCaslon (to name one) and Computer Modern (to name two) to Word

Not much really.

Now, if you do not have admin rights it is more interesting:

  • Right click.
  • Swear.
  • Go to https://portableapps.com/download
  • When asked, select ‘Local — install for current user’ or similar.
  • Finish installing.
  • Use the Explorer to go to: C:\Users\username\PortableApps\PortableApps.com\Data (‘username’ is the login name of the user installing the software).
  • Create a ‘Fonts’ folder in there.
  • Put the OTF files into this folder.
  • Start the Portable Apps Platform (if no shortcut/menu entry is available, go to C:\Users\username\PortableApps\PortableApps.com and run PortableAppsPlatform.exe). If it was started during installation, stop it and restart it.
  • Open Word, say, and LibreCaslon now appears in the fonts menu.
  • Close the Portable Apps Platform and it will not be accessible, though Word might still list it.
  • Add any other fonts you like this way, but they’ll only be available while the Portable Apps Platform is running, and you’ll need to stop it and restart it to make them appear. On the other hand, installation/removal is really simple; to uninstall, turn off the platform and remove from the Fonts folder!

Lots of other great applications (LibreOffice, gnumeric, GIMP, all that) are available through the Portable Apps Platform.

lc_list

Oh, Computer Modern is at https://www.fontsquirrel.com/fonts/computer-modern and https://www.ctan.org/tex-archive/fonts/cm-unicode/fonts/otf.

 

Meh.

Changing the language in Word comment boxes

M$ Word does have a lot of power. It’s very successfully buried. Here’s a thing: the proofing language for the text is set separately from that for any comments you add to the text. It is I suppose a good thing to have separate control over these types of content. The language for comments is determined by the template for the file and may not be what you want. The link below goes to a very useful explanation that shows how to set it to be what you want. I include it here because I found it so useful. I don’t often reblog.

Source: Changing the language in Word comment boxes

Wordy.

Non-breaking en rule (en dash) in Microsoft Word… not really.

Say you’ve got a number range. The proper way to format that is with an en rule (en dash), so it looks something like ‘4­–5’ whereas a hyphen would look like ‘4-5’. Now, you probably don’t want the number range to break across lines. That’s fine with a hyphen, since Ctrl-Shift-Hyphen gives a non-breaking hyphen (in Word). But you don’t want a hyphen you want an en rule. One option is to put in a non-breaking hyphen then make it twice as wide.

  • Highlight the non-breaking hyphen (and the hyphen alone, not any trailing/leading characters or spaces).
  • Right click on the hyphen and select the ‘Font…’ menu, then ‘Advanced’ (rule #1 in Microsoft products: Just about anything worth doing is considered ‘Advanced’).
  • Change the number in the ‘Scale’ box to be about 200%.
  • Exit from the menus.
  • Type an en rule in your document, alongside the stretched hyphen. (Ctrl-Keypad Minus.)
  • Compare.
  • Swear.
  • Use it anyway since it’s the most reasonable alternative. You may want to adjust the height; but will this highly manual fix work if font is then changed? No.
  • Watch while Word mysteriously moves the instruction to widen the characters to random places in the document so you end up with double width text in unexpected places.
  • Swear.
  • Learn LaTeX where all you need to type is \mbox{4–5}.
Dialog box in Microsoft Word for changing character size, position and spacing.

Stretch out the hyphen (or anything else) using the ‘Scale’ box. Gives fixed selections but can type in other values. Something between 175% and 225% usually works. Note: Can also be used to adjust the position if need be.

I have tried putting text in boxes, but the baseline is not maintained – it sits high. Character positions can be adjusted down, but then Word boxes clip the contents. Perhaps there is a better solution? I tried making it an equation, or using a minus character, but neither was really satisfactory. I’d like to hear about a better answer because, sadly, using LaTeX is not always viable.

Non-bresaking en rule in Word; results of stretching a hyphen.

Non-breaking en rule in Word; results of stretching a hyphen.

My Word.