improving empty handling in tools::Rectangle

Thorsten Behrens thb at libreoffice.org
Wed May 8 20:23:22 UTC 2019


Hi Noel, *,

Noel Grandin wrote:
> What I'm doing here is making its behaviour in the empty case more reasonable,
> and adding asserts that will flush out some of the existing dodgy code.
>
Yep, on balance I think that's beneficial.

> I'd be happy to be proven wrong, but I'm not aware of any mechanical
> fixes.
>
Right, and I'm afraid those would obfuscate things even more.

The plan back in the day was to either use float ranges (where - for
graphics - this half vs. closed interval question usually becomes
moot), or B2IBox and B2IRange respectively. And then gradually move
code over to use basegfx & drawinglayer.

From how I see this, that change is best done manual.

Cheers,

-- Thorsten
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 1032 bytes
Desc: not available
URL: <https://lists.freedesktop.org/archives/libreoffice/attachments/20190508/fa67031f/attachment.sig>


More information about the LibreOffice mailing list