/*
	Copyright 2005-2007 Adobe Systems Incorporated
	Distributed under the MIT License (see accompanying file LICENSE_1_0_0.txt
	or a copy at http://stlab.adobe.com/licenses.html)
*/

layout mini_image_size
{
 interface:
    percent: false;

	view dialog (name: "Mini Image Size")
	{
		column(horizontal: align_fill)
		{
					   	
		row(horizontal: align_fill)
		{
			column()
			{
				group (name: "Original Document", horizontal: align_fill)
				{
				   display_number(name: "Height:", bind: @original_height, format: "#",
						units: [{ name: "pixels", format: "#", scale: [ 1, 0 ] }]);
				   display_number(name: "Width:", bind: @original_width, format: "#",
						units: [{ name: "pixels", format: "#", scale: [ 1, 0 ] }]);
				}
				group(name: "Pixels", horizontal: align_fill)
				{
					edit_number(name: "Height:", digits: 7, bind: @height_pixels, format: "#");
					edit_number(name: "Width:", digits: 7, bind: @width_pixels, format: "#" );
				}
            }
			column()
			{
				button(name: "OK", action: @ok, default: true);
				button(name: "Cancel", action: @cancel);
			}
		}
		reveal(name: "Percent", bind: @percent);
		optional(bind: @percent, horizontal: align_fill)
		{
			group(horizontal: align_fill, child_horizontal: align_fill)
			{
				slider(bind: @height_percent, format: {first: 0, last: 200, interval: 1});
				static_text(name: "Height", horizontal: align_center);
				slider(bind: @width_percent, format: {first: 0, last: 200, interval: 1});
				static_text(name: "Width", horizontal: align_center);
			}
		}
		checkbox(name: "Constrain Proportions", bind: @constrain);
		}
	}
}
