koproperty/koreport: sizepolicy and expanding fields

Dag Andersen danders at get2net.dk
Wed Apr 27 09:07:25 BST 2011


Onsdag 27 april 2011 09:31:16 skrev du:
> On 27 April 2011 09:07, Dag Andersen <danders at get2net.dk> wrote:
> > Hi, I'm wondering a bit about the properties "Can Grow" and "Word Wrap"
> > used for the field item. I don't find the functionality very intuitive
> > so I propose to use a (limitied) SizePolicy property instead of Can
> > Grow., that implements Fixed and Expanding.
> 
> Dag,
> Adam has nice screen shots presenting the properties in real use, what
> can help. This would be part of end-user (and API?) documentation too.
> Regarding SizePolicy I believe it's unfortunately exactly opposite:
> it's counter-intuitive in terms of end-user friendliness, even if this
> is informal note:
> - SizePolicy comes not only from developers world (Qt API) and it's
> hard to even translate meaning of the property to some languages
> without using full sentence (think: Polish);
> - SizePolicy comes from QWidget world, there's no reason to harmonize
> reports with QWidgets API, they differ in terms of media type and
> level of abstraction.
Well, it could be named Grow Policy (or someting else...)
> - as for the simplicity, there is no point of having 2-value enum
> Fixed/Expanding instead of boolean value Can Grow, which, by the way
> is OK for someone without QWidget API knowledge (the main user base)
Depends if you want to control horizontal and vertical expansion separately.
I can see that Word Wrap defines which way the field grows. But if expansion is 
limited in some way, word wraping should not affect expansion.

(Btw, the use of the word wrap property to control expansion was what I found 
not intuitive.)
> 
> > Also, imo the expansion should be limited to section size. Horizontally
> > this would mean page right edge.
> 
> This is very true, TODO.
> 
> > Vertically I'm not sure, sections seems not to
> > have a fixed height.
> 
> Good point anyway with another side point: it would be nice to  have
> "Can Grow" property for sections too, true by default.
Hmm, what happens if there is not enough room for the detail section on any 
page, like if e.g. page header takes the whole page?
> 
> > I have a half working solution but I'd like a go ahead to put more time
> > into it.
> 
> OK please show it.

-- 
Mvh.
Dag Andersen



More information about the calligra-devel mailing list