Bug 205715

Summary: "Go to line" minidialog is not resized correctly
Product: [Applications] kate Reporter: Stefan Majewsky <majewsky>
Component: partAssignee: KWrite Developers <kwrite-bugs-null>
Status: RESOLVED FIXED    
Severity: normal CC: kde, toddrme2178
Priority: NOR    
Version: unspecified   
Target Milestone: ---   
Platform: openSUSE   
OS: Unspecified   
Latest Commit: Version Fixed In:
Sentry Crash Report:

Description Stefan Majewsky 2009-08-30 19:26:53 UTC
Version:            (using KDE 4.3.0)
Installed from:    SuSE RPMs

To reproduce:

1. Open an application that embeds katepart.
2. Press "Ctrl-G", the "Go to line" dialog appears.
3. Press "Ctrl-R", the "Find and replace" dialog appears.
4. Press "Ctrl-G", the "Go to line" dialog appears again, but it's too big.
Comment 1 Matthew Woehlke 2009-09-01 22:58:22 UTC
At first I thought you meant the text edit, but I see it is the whole bar area.

I noticed that Find seems to have special code to deal with this (Ctrl-R, Ctrl-F, the bar is momentarily taller with the widgets for 'Find...' shown, and then resizes itself), maybe that's simply missing for 'Go to line...'?

Anyway, confirming: reproducible in at least trunk.

On a related note, I do notice that the text edit starts out at what is apparently a default size, but shrinks to be only big enough for the largest possible value after some showing/hiding of the 'Go to line...' bar. Not sure if that's related.
Comment 2 Dominik Haumann 2010-06-21 00:31:16 UTC
The reason for this is: We use a QStackedWidget, which always has the height of the widget with maximum height. If the replace-bar exists, this the maximum height is very large.

I've tried to always use the preferred height of the widget that is visible. But that's also not what we want, because the height of the goto-bar, the search-bar and the command-line differs in 1-3 pixels. So what we then get is a very jumpily behavior then.

A (probably good) workaround is to remove the replace-viewbar from the viewbar-container once it's hidden. Then the height would be defined by one of the single-line-viewbars.

Any volunteers? :)
Comment 3 Dominik Haumann 2011-06-25 17:40:19 UTC
*** Bug 260389 has been marked as a duplicate of this bug. ***
Comment 4 Dominik Haumann 2011-07-31 16:06:48 UTC
Git commit 1a3c26c4c165c453698df7025cc8ebc8bfc70962 by Dominik Haumann.
Committed on 31/07/2011 at 18:04.
Pushed by dhaumann into branch 'master'.

remove search/replace bar from view bar, to minimize the height

BUG: 205715

M  +5    -1    part/view/kateviewhelpers.cpp
M  +6    -1    part/search/katesearchbar.cpp
M  +2    -1    part/view/kateview.cpp
M  +2    -0    part/search/katesearchbar.h

http://commits.kde.org/kate/1a3c26c4c165c453698df7025cc8ebc8bfc70962