Opened 7 years ago

Closed 3 years ago

#2004 closed enhancement (fixed)

wxgui: ctrl-t to tile layer manager and map window full screen

Reported by: hamish Owned by: grass-dev@…
Priority: normal Milestone: 7.4.0
Component: wxGUI Version: svn-trunk
Keywords: window layout Cc:
CPU: All Platform: All

Description

Hi,

it would be very handy to make ctrl-t tile the layer manager and map window side by side, full screen.

the idea is to read the desktop size in pixels, split it up ~1.7:1 ratio with the wider (squarer) map display on the right, but if that makes the layer manager wider than 700px max it out at that and make the map window wider to fill in the gap between them.

On my system with default (AFAIK) fonts 700px wide layer manager window gets the output window tab and the '>>> ' python prompt tab to allow 80 chars of text to fit without wrapping. (e.g. for r.info report output)

maybe if multiple map windows are open tile them top-to-bottom on the right side.

I'm not sure if it can control the launching Terminal prompt (xterm) window, maybe the best we could do there is split the left-side upper 2/3rds for the layer manager and leave the bottom 1/3rd empty for the user to move the window there themselves? (or just ignore it and make the layer manager be full-height on the left side)

thoughts?

Hamish

Attachments (2)

tile_wxpy_windows.patch (3.5 KB) - added by hamish 7 years ago.
code chunk to tile map display windows (tried in trunk)
grass_gis_ubuntu_1404_tiling_and_menu_search_small.png (220.9 KB) - added by wenzeslaus 6 years ago.
GRASS GIS on Ubuntu (with Unity) using tiling and menu search (HUD). The screenshot was taken on 24 inch screen with 1920 x 1200 (16:10) resolution.

Download all attachments as: .zip

Change History (14)

comment:1 Changed 7 years ago by hamish

Hi,

attached is come code to tile the map windows, but I'm not sure where it should go or how to bind that to ctrl-t in gui_core/forms.py. Ideally the keybinding should work from the layer manager or any map window. (I note that ctrl-q and ctrl-w only work from the layer manager window currently, it would be good to extend that too)

Also the elif cases could probably be better collapsed into something a bit more elegant, it's just proof of concept. No idea how it behaves on a dual monitor setup.

Finally, I notice that you get a beyond index traceback error after you open a fifth+ map display window.

Hamish

Changed 7 years ago by hamish

Attachment: tile_wxpy_windows.patch added

code chunk to tile map display windows (tried in trunk)

comment:2 Changed 6 years ago by hamish

Milestone: 6.4.46.4.5

F11 for fullscreen map canvas in a second monitor would still be nice.

comment:3 Changed 6 years ago by annakrat

Milestone: 6.4.57.1.0

Try r60971 for fullscreen map display. Works also for g.gui.mapswipe/iclass/gcp. I am not sure if we want to keep the toolbars or not. Showing them would be more consistent with other applications but I don't think they are necessary when we can move the map view with mouse only.

comment:4 in reply to:  3 ; Changed 6 years ago by hamish

Replying to annakrat:

Try r60971 for fullscreen map display. Works also for g.gui.mapswipe/iclass/gcp.

awesome, thank you.

I am not sure if we want to keep the toolbars or not. Showing them would be more consistent with other applications but I don't think they are necessary when we can move the map view with mouse only.

can they be set to be turned on and off with a right click context menu? then the preferences file could remember the state.

thanks, Hamish

ps- any thoughts on the usefulness (or not) of the multi-display window tiling patch attached to this ticket?

comment:5 in reply to:  4 Changed 6 years ago by wenzeslaus

Replying to hamish:

ps- any thoughts on the usefulness (or not) of the multi-display window tiling patch attached to this ticket?

I like the idea but I remember when I was looking at the code in the patch, my conclusion was that a lot of work is still required. Moreover, I'm afraid that it will be hard to do it generally, especially in cross-platform manner, for example even the tiling functionality in Ubuntu's Unity does not work perfectly and there are different limitations in Ubuntu 12.04 and 14.04.

Hoverer, general tiling window managers might be pretty good option. The advantage is that you can also layout things like a terminal window. I'm attaching screenshot from from Ubuntu 14.04 (with Unity) where I've used Ctrl+Alt+1 for terminal, Ctrl+Alt+7 for layer manager, and Ctrl+Alt+9 and Ctrl+Alt+3 for map displays. Terminal and especially layer manager are unnecessary long but it was actually quite useful for long commands and long map names.

By the way, the screenshot shows also another Unity's feature, a search in main menu (aka HUD). This started to work with Ubuntu 14.04 (I don't know if because of updates in wxPython, wxWidgets, wxGtk or Unity itself). By this I don't mean that that everybody should start using Ubuntu. My point is that there are some system features which GRASS can benefit from. (Cycling just GRASS windows instead of all using Ctrl+` is advantageous too, by the way.)

Changed 6 years ago by wenzeslaus

GRASS GIS on Ubuntu (with Unity) using tiling and menu search (HUD). The screenshot was taken on 24 inch screen with 1920 x 1200 (16:10) resolution.

comment:6 in reply to:  3 ; Changed 6 years ago by annakrat

Replying to annakrat:

Try r60971 for fullscreen map display. Works also for g.gui.mapswipe/iclass/gcp. I am not sure if we want to keep the toolbars or not. Showing them would be more consistent with other applications but I don't think they are necessary when we can move the map view with mouse only.

r61267 fixes fullscreen on Windows.

comment:7 in reply to:  6 Changed 6 years ago by annakrat

Replying to annakrat:

Replying to annakrat:

r61267 fixes fullscreen on Windows.

Backported in r61488. It doesn't work on Mac but I was not able to set a browser fullscreen either.

comment:8 Changed 5 years ago by neteler

Milestone: 7.1.07.2.0

Milestone renamed

comment:9 Changed 4 years ago by neteler

Milestone: 7.2.07.2.1

Ticket retargeted after milestone closed

comment:10 Changed 4 years ago by martinl

Milestone: 7.2.17.2.2

comment:11 Changed 3 years ago by martinl

Milestone: 7.2.27.4.0

All enhancement tickets should be assigned to 7.4 milestone.

comment:12 Changed 3 years ago by martinl

Resolution: fixed
Status: newclosed

Seems to be solved, closing.

Note: See TracTickets for help on using tickets.