Mintoris Forum

Author Topic: Rect graphics command  (Read 3116 times)

Jesse

  • Sr. Member
  • ****
  • Posts: 126
  • If life throws a planet at you, pull your ripcord‼
Rect graphics command
« on: Apr 27, 2011, 03:18 PM »
I stumbled across an anomaly in the Rect command. If FILL isn't specified, it works ad you'd expect, drawing an empty box at the specified coordinates. But… if you specify FILL, to get a solid box, that solid box is one pixel inside the coordinates. For example, if you issue: Rect 100, 100, 200, 200, 1 -> you get a solid box at 101, 101, 199, 199. So you either have to offset the coordinates by a pixel, or issue a Rect with Fill and another without Fill, to fill in the missing border.

Chuck

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 1899
Re: Rect graphics command
« Reply #1 on: Apr 29, 2011, 09:48 AM »
I think this is just going to have to be a quirk of the language.  The Rect command is just a wrapper around the Java canvas drawRect method which also acts exactly as Jesse describes above. 

Chuck

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 1899
Re: Rect graphics command
« Reply #2 on: Apr 15, 2012, 08:30 PM »
This problem with the Rect command was fixed ages ago.

-Chuck