gIconHeight			= 200;
gIconWidth			= 200;

maxLabelWidth		= max( zstring_width( zstring: '$$$IDS_STAMP_CATEGORY' ), 
						   zstring_width( zstring: '$$$/Dialogs/StampCreate/Name' ) );

gCategoryPopupWidth	= 12 * max_char_width();

dialog( name: '$$$/Dialogs/StampCreate', target_id: 'brws' )
{
	view( align_children: align_left )
	{
		cluster( align_children: align_row, alignment: align_fill )
		{
			view( align_children: align_left, alignment: align_fill )
			{
				picture( item_id: 'prvw', width: gIconWidth , height: gIconHeight, alignment: align_fill, next_tab: 'brws' );
				button( item_id: 'brws', name: '$$$/Dialogs/StampCreate/SelectAppearance', alignment: align_fill, next_tab: 'txt1' );
			}

			view( align_children: align_left, alignment: align_fill )
			{
				view( align_children: align_row, alignment: align_fill )
				{
					static_text( item_id: 'txt1', name: '$$$IDS_STAMP_CATEGORY', width: maxLabelWidth, alignment: align_right, next_tab: 'cate' );
					edit_text( item_id: 'cate', width: gCategoryPopupWidth, PopupEdit: true, alignment: align_fill, next_tab: 'txt2' );
				}

				view( align_children: align_row, alignment: align_fill )
				{
					static_text( item_id: 'txt2', name: '$$$/Dialogs/StampCreate/Name', width: maxLabelWidth, alignment: align_right, next_tab: 'name' );
					edit_text( item_id: 'name', alignment: align_fill, width: 8 * max_char_width(), height: gEditTextHeight, alignment: align_fill, next_tab: 'optc' );
				}

				view( align_children: align_row, alignment: align_fill )
				{
					gap( width: maxLabelWidth );

					check_box( item_id: 'optc', name: '$$$/Dialogs/StampCreate/Optimize', alignment: align_fill, next_tab: 'help' );
				}
			}
		}

		gap();

		ok_cancel_help();
	}
}
