[wx-dev] Re: Something for GSoC2008?
Kit Bishop
kit at bishop.net.nz
Tue Mar 4 14:37:15 PST 2008
Pleased to see this is something others would like. It would certainly
make things easier for me in some areas.
I would have a go at it myself but (a) so far understanding the code has
defeated me :-( ; (b) as ATS says, I think the necessary algorithms are
definitely non-trivial; (c) I don't have a lot of time to spare from
"real life" (you know, earning a $ or two etc.) :-( .
If someone does do some work on it I would be happy to test it out (but
can't commit passed that). If necessary, I could convert from using
wx2.8.7 (on Linux and MSW) to using TRUNK/wx2.9.0 - I've been thinking
of making that move already but not 100% sure what issues I'll have to
tackle or whether it is sufficiently "stable".
Anyway, my thanks will go to anyone who does implement this.
Best regards,
Kit Bishop
ATS wrote:
> Julian Smart <julian at ...> writes:
>
>
>> I agree, dynamic wrapping would be widely welcomed. There was recently a
>> patch (I think applied, but possibly only to trunk?) that alters the
>> sizer system to do just this kind of wrapping, but operating at a sizer
>> level and not an individual control level. Might be applicable though.
>>
>>
>
> The problem wxWrapSizer solves is precisely this on, although wxWrapSizer
> is a bit more general, since it also deals with items of varying height.
>
> It is a non trivial algorithm, since there are a different ways the
> area can be constrained (known vertical or known horizontal extent).
>
> The problem is the same as word processors wrapping paragraphs or
> browsers calculating height of a page of text.
>
>
> The current implementation of wxWrapSizer solves the easiest case,
> when the horizontal extent is known early on and vertical extent is
> asked for later.
>
> I've an submitted updated a patch that is a more full solution. It's
> still in the patch pipe at SF:
>
>
>
>> Whether it's of sufficient scale for a GSoC project I'm not sure...
>>
>>
>
> A solution for text only can be a lot more efficient than 'using a
> wxSizerItem per word'. I'd say it's a big enough problem. Specially
> when tying into layout rendering and the whole sizer machinery. It
> should work smoothly when a dialog is resized for example.
>
>
> Regards
> // ATS
>
>
>> Regards,
>>
>> Julian
>>
>> Kit Bishop wrote:
>>
>>> Something that I would very much like is a "proper" wrapping static text
>>> control.
>>>
>>> Let me explain what I mean:
>>>
>>> At present (wx2.8.7), one can call Wrap on a static text to set the
>>> pixel width at which text should wrap (though it seems it doesn't work
>>> properly on all platforms). I would like a static text that wrapped
>>> automatically.
>>>
>>>
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: wx-dev-unsubscribe at lists.wxwidgets.org
> For additional commands, e-mail: wx-dev-help at lists.wxwidgets.org
>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.wxwidgets.org/pipermail/wx-dev/attachments/20080305/190e4865/attachment.htm
More information about the wx-dev
mailing list