Question

I just started programming J. Now I want to type

text=: 'hello world'
text

in the gtk terminal, which when run should display:

hello world

But when I type the single quote character it renders as ´, not as ' in the gtk terminal. And then when I run the program the interpreter says "spelling error". Now the only way I can put a ' in the terminal is by typing it in notepad and pasting it in the gtk terminal. I find that cumbersome.

Now my question is: Is there an easier way to type a ' in the gtk terminal? I have Windows 7 64 bits version, also 64 bits version of J, version j64-701.

Was it helpful?

Solution

I just encountered this problem as well, and it appears that this is caused by a keyboard setting (controlling whether quotes appear directly or can be used to make é, ë and the like).

This setting can be changed in almost all Windows applications by pressing Left Alt + Shift. After using this combination, the single quotes appeared correctly for me.

HTH.

OTHER TIPS

I've faced exactly the same problem and I found out that it happens in every software that uses GTK+ (Pidgin, GIMP, Geany, etc), if you have set your keyboard to English-International, when you press the single quote(')/double quote(") key, what you get is acute accent(´)/diacritic(¨).

The best solution to me was, adding the English-US keyboard to the list of available keyboards in Windows (yes, this solution is for windows but you can easily do something similar in any SO you are facing the same problem).

And when I want to input an [ ' ], I just press the default combination LEFT CONTROL + SHIFT to toggle between keyboards.

Long shot, but I'm guessing it's a keyboard thing. My French keyboard has a funky layout, and yours (I'm guessing Dutch?) might have one too. I guess I'm lucky, under Vista 64, I get single quotes, with the right key.

I think it's a bug of the specific version of J. I will ask this question to the support of the producers of J.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top