INPopoverController icon indicating copy to clipboard operation
INPopoverController copied to clipboard

Window doesn't consider border width

Open Taiki-San opened this issue 10 years ago • 2 comments

When the window containing the popover and the window is sized, it either forgets to take into consideration the border width, or to move the popover in the window accordingly. It's not a problem when the width is around one pixel, it get serious if you increase it a bit.

Basically, the arrow get truncated: capture decran 2014-06-20 a 13 28 17

From the view debugger of Xcode 6, it seems there is room at the right of the popover, but it's not exploited. capture decran 2014-06-20 a 13 41 27

The issue can be reproduce on the PopoverSampleApp simply with a border width of 3, get obvious around 5.

Taiki-San avatar Jun 20 '14 11:06 Taiki-San

Commit submitted to fix the issue, basically, _popoverBezierPathWithRect: forgot to consider the width of the border when defining the area to draw, assuming 0. However, there is still some issues when the border is wider than the arrow, the window isn't big enough (try with 50). However, should impact much less people than this issue.

Taiki-San avatar Jun 20 '14 12:06 Taiki-San

Worked on it since then, however, I still encounter issues at very high width (but at this point, the issue isn't blocking anymore). However, I'm still having issues resizing the internal view, could anyone help a bit on this part? So far, the patch is on the following repo: https://github.com/TaikiMMT/INPopoverController

Taiki-San avatar Jun 21 '14 00:06 Taiki-San