REBOL3 tracker
  0.9.12 beta
Ticket #0002047 User: anonymous

Project:



rss
TypeBug Statussubmitted Date11-Aug-2013 22:14
Versionalpha 111 Categoryn/a Submitted bykealist
PlatformWindows Severitymajor Prioritynormal

Summary Layout not displaying image correctly
Description Layout is cutting the left and bottom of image! datatype in some cases

I added two examples that show the red edge being cut off on an image! in the default layout

https://raw.github.com/kealist/rebol/master/chip8/layout-bug.r3
Example code
See https://raw.github.com/kealist/rebol/master/chip8/layout-bug.r3

load-gui

for i 105 106 1 [
	print i
	img: make image! reduce [to-pair reduce [i i] white]
	repeat num i [poke img to-pair reduce [0 num - 1] red]
	repeat num i [poke img to-pair reduce [i - 1 num - 1] red]
	repeat num i [poke img to-pair reduce [num - 1 0] red]
	repeat num i [poke img to-pair reduce [num - 1 i - 1] red]
	view layout [image img]
] 

This changes if other elements are in the layout. See:

for i 129 130 1 [
	print i
	img: make image! reduce [to-pair reduce [i i] white]
	repeat num i [poke img to-pair reduce [0 num - 1] red]
	repeat num i [poke img to-pair reduce [i - 1 num - 1] red]
	repeat num i [poke img to-pair reduce [num - 1 0] red]
	repeat num i [poke img to-pair reduce [num - 1 i - 1] red]
	view layout [button image img]
]

img: make image! reduce [450x450 white]
repeat num-x 10 [
	repeat num-y 100 [
		poke img to-pair reduce [(439 + num-x - 1) (339 + num-y)] black
	]
]
repeat num-x 10 [
	repeat num-y 100 [
		poke img to-pair reduce [(num-x - 1) (339 + num-y)] black
	]
]
view layout [image img]

Assigned ton/a Fixed in- Last Update13-Aug-2013 05:50


Comments
(0003917)
kealist
13-Aug-2013 05:37

Edited original description and added two other examples that clearly show the layout cutting off image! edges

Date User Field Action Change
13-Aug-2013 05:50 kealist Description Modified -
13-Aug-2013 05:50 kealist Code Modified -
13-Aug-2013 05:37 kealist Comment : 0003917 Added -
13-Aug-2013 05:36 kealist Summary Modified Image display cutting off right edge => Layout not displaying image correctly
13-Aug-2013 05:36 kealist Description Modified -
13-Aug-2013 05:36 kealist Code Modified -
11-Aug-2013 22:14 kealist Ticket Added -