tabula-java icon indicating copy to clipboard operation
tabula-java copied to clipboard

Rectangle class has wrong constructor

Open ghost opened this issue 7 years ago • 2 comments

The 4 parameters constructor of the class Rectangle calls the method setRect with a wrong order. the constructor is Rectangle(float top, float left, float width, float height) but it calls the method with a twisted order thiss.setRect(left, top, width, height);

ghost avatar Oct 23 '18 16:10 ghost

@fabcan I believe this all works correctly; the Rectangle2D class is what defines setRect and it wants the x coord first. The Rectangle class is defined in Tabula and takes the top coordinate first. Am I missing something?

jeremybmerrill avatar Nov 25 '18 21:11 jeremybmerrill

@jeremybmerrill I think it's confusing to use different ordering systems, but it's probably too late to change it

ghost avatar Nov 26 '18 08:11 ghost