Mantis Bugtracker
  

Viewing Issue Simple Details Jump to Notes ] View Advanced ] Issue History ] Print ]
ID Category Severity Reproducibility Date Submitted Last Update
0001562 [tweak] Any minor always 07-27-05 01:46 07-27-05 01:46
Reporter elenzil View Status public  
Assigned To
Priority normal Resolution open  
Status new  
Summary 0001562: default size of a null CLabel is large.
Description if you pass an empty string ('') to a CLabel>>label:,
the resulting CPlayer has a size substantially larger than if you pass a non-empty string such as 'hi' or ' '.

if you specify the label's resizing to be #shrinkWrap, the results for empty and non-empty strings are consistent.
which is an argument for making #shrinkWrap the defaulkt resizing mode!
(http://bugs.impara.de/view.php?id=1561) [^]

attached screenshot is generated by the following code:
-----------------------------------------------------------------------------
    w1 _ CWindow new.
    w1 layout: CTableLayout new.
    w1 layout listDirection: #topToBottom.

    row _ CPlayer new.
    row layout: CTableLayout new.
    row layout listDirection: #leftToRight.
    row hResizing: #spaceFill.
    row vResizing: #shrinkWrap.

    l _ CLabel new.
    l label: 'hi'.
    l borderStyle: #simple.
    l borderWidth: 1.
    l borderColor: Color green.

    row add: l.
    w1 add: row.

    row _ CPlayer new.
    row layout: CTableLayout new.
    row layout listDirection: #leftToRight.
    row hResizing: #spaceFill.
    row vResizing: #shrinkWrap.

    l _ CLabel new.
    l label: ''.
    l borderStyle: #simple.
    l borderWidth: 1.
    l borderColor: Color blue.

    row add: l.
    w1 add: row.


    l _ CLabel new.
    l label: 'The above is a label "hi" and
a label "".
Note that the defult height
of "" is quite large.'.

    w1 add: l.

    w1 open.
-----------------------------------------------------------------------------
Additional Information
Attached Files  nulllabelsize.png [^] (3,286 bytes) 07-27-05 01:46

- Relationships

There are no notes attached to this issue.

- Issue History
Date Modified Username Field Change
07-27-05 01:46 elenzil New Issue
07-27-05 01:46 elenzil File Added: nulllabelsize.png


Mantis 1.0.8[^]
Copyright © 2000 - 2007 Mantis Group
29 total queries executed.
24 unique queries executed.
Powered by Mantis Bugtracker