This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 178284 - Fold preview takes too much space
Summary: Fold preview takes too much space
Alias: None
Product: editor
Classification: Unclassified
Component: Code folding (show other bugs)
Version: 6.x
Hardware: All All
: P3 normal (vote)
Assignee: mslama
Depends on:
Reported: 2009-12-08 03:41 UTC by Jiri Prox
Modified: 2009-12-22 23:43 UTC (History)
2 users (show)

See Also:
Issue Type: DEFECT
Exception Reporter:

screen shot (37.46 KB, image/png)
2009-12-08 03:42 UTC, Jiri Prox
Patch (3.17 KB, text/plain)
2009-12-14 11:55 UTC, mslama
Patch with added constructor parameter (5.56 KB, text/plain)
2009-12-15 05:41 UTC, mslama

Note You need to log in before you can comment on or make changes to this bug.
Description Jiri Prox 2009-12-08 03:41:38 UTC
Product Version: NetBeans IDE 6.8 (Build 200912041610)
Java: 1.6.0_16; Java HotSpot(TM) Client VM 14.2-b01
System: Linux version 2.6.31-16-generic running on i386; UTF-8; en_US (nb)

Fold preview (popup which is shown when hovering mouse over collapsed fold) takes too much space if the folded code is quite short.  See the screenshot
Comment 1 Jiri Prox 2009-12-08 03:42:27 UTC
Created attachment 92254 [details]
screen shot
Comment 2 Vitezslav Stejskal 2009-12-10 04:13:14 UTC
Looks ugly. My guess is that the bottom part is the padding that we added some time ago to make editing at a position close to the end of a document slightly more convenient.
Comment 3 mslama 2009-12-10 07:40:56 UTC
It is regression because bottom padding was added to editor view. It should be disabled for tooltip view.
Comment 4 mslama 2009-12-14 11:55:16 UTC
Created attachment 92555 [details]
Comment 5 Vitezslav Stejskal 2009-12-15 01:00:14 UTC
Marku, wouldn't it be possible to pass the boolean flag simply to the constructor of GapDocumentView? Having protected non-final field that's supposed to be modified by subclasses does not sound like a good API design to me.
Comment 6 mslama 2009-12-15 05:41:13 UTC
Created attachment 92601 [details]
Patch with added constructor parameter
Comment 7 mslama 2009-12-22 06:45:05 UTC
jet-main #27febef72bc3

Field is made final to be able to set it just once in constructor.
Comment 8 Quality Engineering 2009-12-22 23:43:43 UTC
Integrated into 'main-golden', will be available in build *200912230201* on (upload may still be in progress)
User: Marek Slama <>
Log: #178284: Fold preview takes too much space.