<div dir="ltr"><div dir="ltr"><div class="gmail_default" style="font-family:tahoma,sans-serif"><br></div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Thu, 19 Mar 2020 at 17:14, Luboš Luňák <<a href="mailto:l.lunak@collabora.com">l.lunak@collabora.com</a>> wrote:</div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">- internal representation will be whatever sane thing will work, e.g. <br>
x,y,width,height , and it won't matter for the API<br>
- empty rectangle is simply width == 0 || height == 0<br><br></blockquote><div><br></div><div class="gmail_default" style="font-family:tahoma,sans-serif">+1 on this part. </div><div class="gmail_default" style="font-family:tahoma,sans-serif"><br></div><div class="gmail_default" style="font-family:tahoma,sans-serif">FWIW, the Java Rectangle API is pretty much this.</div><div class="gmail_default" style="font-family:tahoma,sans-serif"><br></div><div class="gmail_default" style="font-family:tahoma,sans-serif">One important thing - we will need to choose a fundamental type i.e</div><div class="gmail_default" style="font-family:tahoma,sans-serif">float32/float64/int32/int64 for the co-ords.</div><div class="gmail_default" style="font-family:tahoma,sans-serif"><br></div><div class="gmail_default" style="font-family:tahoma,sans-serif">All of these have the normal pro's and con's when it comes to graphics APIs.</div><div class="gmail_default" style="font-family:tahoma,sans-serif"><br></div><div class="gmail_default" style="font-family:tahoma,sans-serif">With one extra wrinkle: the current tools::Rectangle uses long, and lots of places that work with tools::Rectangle also use long, which is particularly pernicious because long is a different bit-size on Windows and Linux.</div><div class="gmail_default" style="font-family:tahoma,sans-serif"><br></div></div></div>