Can't seem to make all caps automatically appear in JCross

54 views
Skip to first unread message

Peggy Rolfsen

unread,
Jan 5, 2025, 1:40:52 PMJan 5
to hotpotatoesusers
I've gone to "Manage Grid," and "Force upper case" is selected, but lower case letters appear in the crossword when I view it in my browser. I'm using version 7 in Chrome, Windows 10.

Martin Holmes

unread,
Jan 5, 2025, 3:08:30 PMJan 5
to hotpotatoesusers
Hi there,

Users are always able to enter lower-case or upper-case letters if they want, but it makes no difference to the checking or to the score.

If you want to force user input to be upper-cased automatically, you would have to add something to the JavaScript that inserts the guess into the grid. You could do that by changing line 166 of jcross7.js_ from this:

SplitStringToPerceivedChars(Guess, PC);

to this:

SplitStringToPerceivedChars(Guess.toUpperCase(), PC);

Cheers,
Martin

Peggy Rolfsen

unread,
Jan 5, 2025, 3:19:52 PMJan 5
to hotpotatoesusers
In the past, it has always been true that no matter what the user typed, the letters always displayed as upper case in the puzzle. That's what the instructions say also:




Case sensitivity in JCross

Normally, JCross upper-cases letters you type into the grid automatically. On the Manage Grid menu, you'll find a menu item Force upper case. This is a checkable item. In other words, it can be on or off; when it's on, its icon appears pressed down, and when it's off, it looks normal. The default is on, meaning that when you type into the grid, your letters will be upper-cased automatically. If you turn it off, you will be able to type lower case letters into the grid.


Martin Holmes

unread,
Jan 5, 2025, 4:05:15 PMJan 5
to hotpotatoesusers
Hi there,

This applies to you, as the instructor creating the exercise in JCross. It has never applied to students doing the exercise in their web browser.

Cheers,
Martin

Peggy Rolfsen

unread,
Jan 5, 2025, 4:14:20 PMJan 5
to hotpotatoesusers
Even if I'm viewing the exercise my web browser?

I don't know how to edit the javascript.

Martin Holmes

unread,
Jan 5, 2025, 6:09:28 PMJan 5
to hotpotatoesusers
Hi Peggy,

The exercise doesn't know the difference between you viewing it and your students viewing it; it's just a web page.

There are some teaching scenarios and language contexts in which the difference between upper and lower case is significant, and teachers want to allow their students to differentiate. So in the web browser, we allow you to enter upper case or lower case, as you wish. But when you're creating the exercise, you can specify that your own interface shows only upper-case, meaning that if a student requests that answers be filled in for them via hints, they'll be in upper-case.

Does it really matter whether your students type in upper- or lower-case?

Cheers,
Martin

Peggy Rolfsen

unread,
Jan 5, 2025, 6:54:03 PMJan 5
to hotpotatoesusers
OK, I understand. And I guess it's not a big deal. But some of the words to be filled in are proper nouns (names); others aren't, and when a proper noun intersects with another word, like in the middle of the word, it ends up looking strange:

Capture1.JPG

I am certain that it wasn't always this way; I have some crosswords made several years ago that function the way I want them to. For example, on this screen capture, although I typed the word in lower case letters, when I hit "Enter," the letters were all changed to upper case in the puzzle:

Capture 2.JPG

Martin Holmes

unread,
Jan 5, 2025, 7:21:25 PMJan 5
to hotpotatoesusers
Hi there,

The following change was made in response to user requests in 2007:

QUOTE:
21/02/2007
JCross

This is an enhancement rather than a bugfix. Previously, all text entered into the grid was upper-cased automatically, and answer-checking in the exercise was case-insensitive.

You can now turn off the "Force upper case" feature on the Manage Grid menu, to enter lower-case letters, and turn on case-sensitivity in answer checking in the Configuration screen. This involves several changes to jcross6.js_.

Thanks to: Lots of people

Added in 6.2.0.6 (21/02/2007).
END QUOTE

So I guess you must have been using a version which was older than this. There is a tutorial on how to edit the source files here:

https://hotpot.uvic.ca/howto/editsource.htm

and that will show you how to make the change you would like to make.

Hope this helps,
Martin

Peggy Rolfsen

unread,
Jan 5, 2025, 7:47:05 PMJan 5
to hotpotatoesusers
Oh, my goodness! I actually got it to work, using all of your suggestions. Thank you so much for spending your Sunday helping me! :-)

Martin Holmes

unread,
Jan 5, 2025, 7:59:15 PMJan 5
to hotpotatoesusers
Congratulations! Now you can make Hot Potatoes work any way you like!
Reply all
Reply to author
Forward
0 new messages