! Please note that this is a snapshot of our old Bugzilla server, which is read only since May 29, 2020. Please go to gitlab.xfce.org for our new server !
Irritating Geometry when using Tabs
Status:
RESOLVED: FIXED
Product:
Xfce4-terminal
Component:
General

Comments

Description Ali Akcaagac 2016-07-31 10:42:24 CEST
Hi and thanks for updating xfce4-terminal and the support for gtk3.

I would like to report an issue that I believe needs a bit more investigating.

I have the terminal set up - to open a new terminal window without menu and other components inside. So bascily what I get is a VTE with a border (and title) around it and a default size of 80x24 chars.

It looks *similar* like this (an old screenshot for a different bug):
https://bugzilla.redhat.com/attachment.cgi?id=940157

With the old xfce4-terminal gtk2 (and all other terminals that support tab'ing), the terminal keeps the default size of 80x24 chars and adds a TAB (notebook widget) ontop of that VTE. So the geometry of 80x24 chars + Notebook size is given. The window get's a bit bigger (to the bottom) because the Notebook widget is being placed ontop of the VTE. But with every TAB I open, the geometry stays 80x24 chars. It's guaranteed that the terminal keeps the size that I inteded it to open (you can change the geometry in the preferences).

With the new xfce4-terminal gtk3, unfortunately when opening a new tab, the tab (Notebook widget) reduces the geometry of the VTE window. What was 80x24 chars will now become 80x21 chars (removing 3 rows from the VTE geometry).

This is a bit strange - and not the expected behaviour. The window geometry needs to remain 80x24 chars (or whatever was specified within the preferences). The Notebook widget has to be added ontop of the 80x24 chars and not reduce the size of 80x24 chars to 80x21 chars.

And now imagine this.

I open 3 Tabs:

The first window is 80x24
The second window (tab) reduces both windows to 80x21
The third window (tab9 stays at 80x21

Now I untie two tabs and I get 80x21 windows (rather than the 80x24 windows). Only the initial window will be back at 80x24.

What I would like to see is this:

1) Terminal 80x24
2) Open a Tab: Window stays at 80x24 + Notebook ontop of that
3) Untieing (dragging out) a Tab: Window should stay at 80x24 chars
4) Closing one or more Tabs: Window stays at 80x24
5) Last Tab closed: Last Window should stay at 80x24
Comment 1 poma 2016-07-31 16:00:05 CEST
What you describe is the same case as with gnome-terminal

$ rpm -q gtk3 vte291 gnome-terminal xfce4-terminal
gtk3-3.20.6-1.fc24.x86_64
vte291-0.44.2-1.fc24.x86_64
gnome-terminal-3.20.2-2.fc24.x86_64
xfce4-terminal-0.7.0-101.20160729gitfbf7c01.fc24.x86_64

Therefore, if you consider it as a bug, you can file it here
https://bugzilla.gnome.org
Comment 2 Ali Akcaagac 2016-07-31 17:01:51 CEST
(In reply to poma from comment #1)
> What you describe is the same case as with gnome-terminal

Yeah you are right. I just installed gnome-terminal and tested it. Looks like something has changed over the time.

If I understand it correctly the entire vte widget is bound with the notebook widget and acts as one thing.

Never mind then. It can stay that way as long as it matches other terminals. Though it's irritating.

$ rpm -q gtk3 vte291 gnome-terminal xfce4-terminal
gtk3-3.20.6-1.fc24.x86_64
vte291-0.44.2-1.fc24.x86_64
gnome-terminal-3.20.2-2.fc24.x86_64
xfce4-terminal-0.6.90-1.fc24.x86_64
Comment 3 Igor editbugs 2016-07-31 20:15:15 CEST
Yeah, this seems like something that has been changed in the vte for some reason.
It also looks unnatural to me but I cannot see how this behavior could be overridden.
Comment 4 Igor editbugs 2016-08-01 16:47:52 CEST
Actually, I fixed this with https://git.xfce.org/apps/xfce4-terminal/commit/?id=39f966d868bd335ea69677581e3d9fed053a45b0

Indeed, this is the behavior of gnome-terminal; but, in contrary, xfce4-terminal had its own mechanism to increase window height when adding tabs bar or toolbar in order to keep number of terminal rows constant. The thing was that the mechanism wasn't working properly under GTK 3.20 so I disabled it. But it has been fixed recently so after I've enabled it back it seems to be working and keeping the terminal size.
Comment 5 poma 2016-08-02 11:09:59 CEST
(In reply to Igor from comment #4)
> Actually, I fixed this with
> https://git.xfce.org/apps/xfce4-terminal/commit/
> ?id=39f966d868bd335ea69677581e3d9fed053a45b0
> 
> Indeed, this is the behavior of gnome-terminal; but, in contrary,
> xfce4-terminal had its own mechanism to increase window height when adding
> tabs bar or toolbar in order to keep number of terminal rows constant. The
> thing was that the mechanism wasn't working properly under GTK 3.20 so I
> disabled it. But it has been fixed recently so after I've enabled it back it
> seems to be working and keeping the terminal size.


Original Terminal window:
$ xwininfo | grep geometry
  -geometry 1054x634+0+39

Opened Tab window:
$ xwininfo | grep geometry
  -geometry 1054x675+0+39

"Tabbar" height is: 675 - 634 = 41
so dimensions are consistent

Closed Tab - back to the Original Terminal window:
$ xwininfo -stats | grep geometry
  -geometry 1054x634+0+39


However ...

Original Terminal window:
$ xwininfo | grep geometry
  -geometry 1054x634+0+39

Opened Tab window:
$ xwininfo | grep geometry
  -geometry 1054x675+0+39

Detached Tab window:
$ xwininfo | grep geometry
  -geometry 1042x602+0+39


 ... Detached Tab window - 1042x602
is lower and narrower compared to
Original Terminal window - 1054x634
Comment 6 Igor editbugs 2016-08-02 11:15:26 CEST
poma, thanks again for verification!

Yes, I've also noticed that the detached window is lacking height in comparison to the original one. This has been happening before commit 39f966d868bd335ea69677581e3d9fed053a45b0, and this is also happening in gnome-terminal.
I'm thinking that maybe force_resize_window() function should be called on detaching a tab; I will look into this.
Comment 7 Igor editbugs 2016-08-02 11:49:30 CEST
The detaching tab issue is fixed with https://git.xfce.org/apps/xfce4-terminal/commit/?id=c66bc94acf273a20f72a3eab03c237122a310d3f
Comment 8 poma 2016-08-02 14:22:20 CEST
(In reply to Igor from comment #7)
> The detaching tab issue is fixed with
> https://git.xfce.org/apps/xfce4-terminal/commit/
> ?id=c66bc94acf273a20f72a3eab03c237122a310d3f

...
Detached Tab window:
$ xwininfo | grep geometry
  -geometry 1054x634+0+39

Dimensions are consistent across Terminal windows.
Comment 9 Ali Akcaagac 2016-08-02 14:49:40 CEST
I will test the new changes as soon as I find a bit time. But so far here are a few other things related to geometry:

-------------------

Zoom In / Zoom Out
Font becomes bigger or lower but the Window remain the same size.

Open a new Window (in case you have zoomed in before) and the new Window is bigger. Zooming out or zooming reset won't resize the Window to fit the geometry (as 80x24 for example).

-------------------

Under really rare ocasions I detect that when opening a new Window from within an running terminal (right mouse on the terminal and → open Terminal), that the new terminal opens with smaller font (even though no zoom has been used). This is hard to reproduce but occoured a few times.

And thanks again for the work. I really like the new Terminal and the new VTE it uses.
Comment 10 Ali Akcaagac 2016-08-02 14:50:34 CEST
Btw: Still on 0.6.90 release tar.
Comment 11 Igor editbugs 2016-08-02 15:08:28 CEST
>Zoom In / Zoom Out
>Font becomes bigger or lower but the Window remain the same size.
Yes, this was the case previously but one of the latest commits has changed the behavior: on the git version, the window is getting smaller/bigger on font changes, maintaining numbers of rows and columns.

>Under really rare ocasions I detect that when opening a new Window from within an running terminal (right mouse on the terminal and → open Terminal), that the new terminal opens with smaller font (even though no zoom has been used). This is hard to reproduce but occoured a few times.
I have never noticed this. Please keep an eye on it.

>And thanks again for the work. I really like the new Terminal and the new VTE it uses.
Thank you!
Comment 12 poma 2016-08-02 19:30:43 CEST
Zoom
Level  Geometry      Ratio              Geometry      Ratio

-7:     396 x  202 - 1.96039604    ↷         ≑
-6:     396 x  250 - 1.584        ↑  ↓       ≑
-5:     414 x  274 - 1.510948905  ↑  ↓   489 x  274 - 1.784671533
-4:     494 x  298 - 1.657718121  ↑  ↓   584 x  298 - 1.959731544
-3:     654 x  394 - 1.659898477  ↑  ↓   774 x  394 - 1.964467005
-2:     654 x  418 - 1.564593301  ↑  ↓   774 x  418 - 1.851674641
-1:     894 x  538 - 1.661710037  ↑  ↓  1059 x  538 - 1.968401487
 0:    1054 x  634 - 1.662460568  ⇅  ↓  1249 x  634 - 1.970031546
+1:    1294 x  754 - 1.716180371  ⇅  ↓  1534 x  754 - 2.034482759
+2:    1534 x  898 - 1.708240535  ⇅  ↓  1819 x  898 - 2.025612472
+3:    1774 x 1066 - 1.664165103  ⇅  ↓  2104 x 1066 - 1.973733583
+4:    2174 x 1306 - 1.664624809  ⇅  ↓  2579 x 1306 - 1.974732006
+5:    2654 x 1546 - 1.716688228  ⇅  ↓  3149 x 1546 - 2.03686934
+6:    3134 x 1834 - 1.708833152  ⇅  ↓  3719 x 1834 - 2.02780807
+7:    3774 x 2194 - 1.720145852  ◎  ◎  4479 x 2194 - 2.041476755


Ratio is problematic, particularly increasing from negative zoom levels.

For comparison,
gnome-terminal doesn't resize window during zooming.
Comment 13 poma 2016-08-02 19:43:00 CEST
(In reply to Ali Akcaagac from comment #9)
> I will test the new changes as soon as I find a bit time. But so far here
> are a few other things related to geometry:
> 
> -------------------
> 
> Zoom In / Zoom Out
> Font becomes bigger or lower but the Window remain the same size.
> 

with gnome-terminal, not with xfce4-terminal - git current,
try with mate-terminal ;)


> Open a new Window (in case you have zoomed in before) and the new Window is
> bigger. Zooming out or zooming reset won't resize the Window to fit the
> geometry (as 80x24 for example).
> 

Yes and no, depends on the zoom level and how it is reached.

> -------------------
> 
> Under really rare ocasions I detect that when opening a new Window from
> within an running terminal (right mouse on the terminal and → open
> Terminal), that the new terminal opens with smaller font (even though no
> zoom has been used). This is hard to reproduce but occoured a few times.
> 

Not here.

Bug #12734

Reported by:
Ali Akcaagac
Reported on: 2016-07-31
Last modified on: 2016-08-02

People

CC List:
2 users

Version

Version:
0.6.90

Attachments

Additional information