Yes, thatÅ› right. For horizontal scroll, it's very difficult to do a pixel precise frame scroll. It does it in 8 pixels wide blocks. Doing it pixel perfect, due to ZX Spectrum architecture, would be really slow. I still can provide you a scroll routine that does exactly that, but be aware that it will be REALLY slow.
For vertical scroll this does not happen and it's pixel perfect.
A simple solution is to place your rectangle in an aligned zone.
You can draw the box frame out of the inner part that will be scrolled:
This should work
One more thing: Float is REALLY slow and expensive. Consider using Fixed instead of Float and only if necessary. Most of the time you will need just Uinteger or Ubyte values.
For vertical scroll this does not happen and it's pixel perfect.
A simple solution is to place your rectangle in an aligned zone.
You can draw the box frame out of the inner part that will be scrolled:
Code:
square(7, 15, 80, 60, 6)
One more thing: Float is REALLY slow and expensive. Consider using Fixed instead of Float and only if necessary. Most of the time you will need just Uinteger or Ubyte values.