AndrewRigg / Crossword

Crossword Generator made by Steven Court
0 stars 0 forks source link

Crossword highlight from anywhere #95

Closed Golpette closed 7 years ago

Golpette commented 7 years ago

A wee bit more fiddly than I anticipated. Have a play with the new crossword highlighting.

Basically, the change means you should now be able to highlight across/down from any position. I also stopped it automatically starting new words. I think it's better now.

I think it's bug free, but I altered methods that were connected to arrow keys, text entry and mouse clicking, so try all manoeuvres you can imagine and tell me if you spot any bugs that I didn't!

(I still didn't get it to refocus after zooming. There is a super-weird bug somewhere when I add this, that i still need to find).

AndrewRigg commented 7 years ago

bug1 bug2

Looking really good, although do you think it is actually preferable to select the whole word rather than a letter? I think I got used to selecting the word and quite liked it. Although then it would be frustrating if you actually want just one letter (although why would you ever try to fill in a word not from the start?!) I notice that you can still select the clue to get the word from the start so that's there anyway I suppose.

There was a really weird and annoying bug on mine which seemed to happen about 1/5th of the time which is demonstrated in the two images attached. As you can see the cursor is on the same place in each and the letter is different but no word has been selected. Basically it sometimes fails to highlight a new word and so a letter can be edited in one box without every moving on. Actually the previous word is still highlighted but the cursor has moved. It might just require updating the highlighted word before moving the cursor.

Golpette commented 7 years ago

Ok that's interesting, I have not seen that bug you found in the images... can you remember exactly what process led to it?

I thought about word vs letter - but if you forced it to go to start of word, then it would be a hassle to correct typos! You'd have to type the whole word again. If you want to select word, you can easily click the first letter OR the clue on the right hand side, so I think what it is now makes more sense. You?

Golpette commented 7 years ago

I'll leave it for now. I've tried everything I could think of but can't ever generate that problem...

Let me know when you see it again please.

AndrewRigg commented 7 years ago

Sorry, yes I think you're right with the design decision - let's go with that. Em the bug basically happened once every 5th or so time I pressed on a box. I just clicked on one, then another then another and so on in quick succession until that happened. Perhaps it is just on my system. I'll merge the pull request now and then try to fix it on my laptop, and if I can I'll make another pull request which you can try and if it still works we can merge that one.

Golpette commented 7 years ago

Right... I think I spotted it but it's not a bug in the code.

If I DOUBLE click and drag on a square I can select it without actually highlighting the word.

It does not happen if I double click. Even if I double click and hold for a long time, as long as the mouse is still over the box it will go green.

The ONLY time I can get this is if i double click, then drag the mouse away from the box.

Is it possible you were doing this if you were clicking really fast?

Maybe there is some sort of "click" we can just disable. Like make double clicks the same as single... I dunno...

Remember and make a new branch