Diagonal scrolling with arrow keys
Moderator: OpenTTD Developers
Diagonal scrolling with arrow keys
As I always have used the arrow keys for scrolling, I really miss the way this works in TTD. I want to be able to scroll diagonal by pressing two arrow keys.
And scrolling faster with shift-key does behave strange, you have to press the shift key first and then the arrow key to make it scroll faster, which is very annoying.
I saw a feature request for this at source forge, but there were no comments given.
Just wonder if there are any plans to "fix" this ?
And scrolling faster with shift-key does behave strange, you have to press the shift key first and then the arrow key to make it scroll faster, which is very annoying.
I saw a feature request for this at source forge, but there were no comments given.
Just wonder if there are any plans to "fix" this ?
In TTD I always "scroll" with the help of the "C-key" (center on the mousecursor).
This way you can scroll in any direction and nearly at any speed. Just move the cursor into the direction dat you want to scroll, and press C, once or mutiple times. The screen gets redrawn with the new center at the position of the mousecursor.
If you move the mousecursor at the edge of the screen you'll scroll fast and if you place it in the corner of the screen you'l scroll diagonally.![Very Happy :D](./images/smilies/icon_biggrin.gif)
This way you can scroll in any direction and nearly at any speed. Just move the cursor into the direction dat you want to scroll, and press C, once or mutiple times. The screen gets redrawn with the new center at the position of the mousecursor.
If you move the mousecursor at the edge of the screen you'll scroll fast and if you place it in the corner of the screen you'l scroll diagonally.
![Very Happy :D](./images/smilies/icon_biggrin.gif)
Wie zich gelukkig voelt met het geluk van anderen, bezit een rijkdom zonder grenzen. (F.Daels)
![Image](https://imageproxy.tt-forums.net/2f977728952cc158390687ccb3ca445c7d7d025e/687474703a2f2f636f2e686f6d65646e732e6f72672f616e6930372e676966)
Still the best OS around
Still the best OS around
Oh, didn't know you could do this, have to tryRob wrote:In TTD I always "scroll" with the help of the "C-key" (center on the mousecursor).
This way you can scroll in any direction and nearly at any speed. Just move the cursor into the direction dat you want to scroll, and press C, once or mutiple times. The screen gets redrawn with the new center at the position of the mousecursor.
If you move the mousecursor at the edge of the screen you'll scroll fast and if you place it in the corner of the screen you'l scroll diagonally.
![Smile :)](./images/smilies/icon_smile.gif)
Scrolling
Hello,
Yesterday, late in the night, I added a little quick patch on sourgeforge.net that allows to use the middle button of your mouse instead of the C key for the same result...
Could you try it ? (I joined the patch to this post)
(The code isn't finished in the sense it is only for windows for the moment, and there's no way to turn it off, but if you guys like it, I could finish the implementation...)
Testman57 (once was marked as a developer for OpenTTD
)
Yesterday, late in the night, I added a little quick patch on sourgeforge.net that allows to use the middle button of your mouse instead of the C key for the same result...
Could you try it ? (I joined the patch to this post)
(The code isn't finished in the sense it is only for windows for the moment, and there's no way to turn it off, but if you guys like it, I could finish the implementation...)
Testman57 (once was marked as a developer for OpenTTD
![Sad :(](./images/smilies/icon_sad.gif)
- Attachments
-
- middle_scroll.patch
- The first draft patch itself
- (1.97 KiB) Downloaded 247 times
Re: Scrolling
you could be that again if you are more active. We removed the people, who didn't submit anything for a long while and the current developers didn't even knowtestman wrote:Testman57 (once was marked as a developer for OpenTTD)
The problem for the linux version is that I don't seem able to compile using SDL correctly (Openttd tries to lauch but exits directly without any error...)
I think I could do the code blindly, but then it would be very random as a result (I think the code to be changed is in the the "case SDL_MOUSEBUTTONDOWN and SDL_MOUSEBUTTONUP" section, it only needs to set _middle_button_down = true and _middle_button_clicked = true in the event of a SDL_BUTTON_MIDDLE, it is quite straightforward... but I have temporarly no access to my dev pc
...
I Hope I can do it this evening...
-- edit --
Here is an update to the patch, it *should* now work with sdl (and linux...), but I can't give any warranty, as I am not able to test it under linux, not even with sdl under windows...
Happy testing, and any comment would be welcome
(I already have some improvements on mind)
Testman57
I think I could do the code blindly, but then it would be very random as a result (I think the code to be changed is in the the "case SDL_MOUSEBUTTONDOWN and SDL_MOUSEBUTTONUP" section, it only needs to set _middle_button_down = true and _middle_button_clicked = true in the event of a SDL_BUTTON_MIDDLE, it is quite straightforward... but I have temporarly no access to my dev pc
![Sad :(](./images/smilies/icon_sad.gif)
I Hope I can do it this evening...
-- edit --
Here is an update to the patch, it *should* now work with sdl (and linux...), but I can't give any warranty, as I am not able to test it under linux, not even with sdl under windows...
Happy testing, and any comment would be welcome
(I already have some improvements on mind)
Testman57
- Attachments
-
- middle_scroll2.patch
- (2.73 KiB) Downloaded 254 times
Last edited by testman on 30 May 2004 18:02, edited 1 time in total.
Greatdominik81 wrote:Diagonal arrow scrolling is in SVN by the way (at least for SDL, I don't know about Win32).
![Smile :)](./images/smilies/icon_smile.gif)
I just tried and it worked fine, but there is one little thing with scrolling that still annoys me...
When you press an arrow-key + shift-key to scroll faster, and then release the shift-key without releasing the arrow-key, the scrolling stops. You have to release the arrow-key and press it again to continue scrolling, which I think shouldn't be needed.
Did you get me ?
![Smile :)](./images/smilies/icon_smile.gif)
Who is online
Users browsing this forum: No registered users and 1 guest