gMaxCertPropWidth = max(
	zstring_width(zstring: '$$$/Dialogs/FieldProps/Barcode/Security/Cert/Issuer'),
	zstring_width(zstring: '$$$/Dialogs/FieldProps/Barcode/Security/Cert/Subject'),
	zstring_width(zstring: '$$$/Dialogs/FieldProps/Barcode/Security/Cert/ValidFrom'),
	zstring_width(zstring: '$$$/Dialogs/FieldProps/Barcode/Security/Cert/ValidTo')
	);
gPropColumnWidth = max_char_width() * 2 + gMaxCertPropWidth;
gClusterWidth = 360;
gClusterHeight = 160;
	
dialog(name: '$$$/Dialogs/FieldProps', target_id: 'secr', first_tab: 'secr')
{
    view(align_children: align_left, alignment: align_fill)
    {
		check_box(item_id: 'secr', name: '$$$/Dialogs/FieldProps/Barcode/Security/SecureContents');
		cluster(item_id: 'cprp', name: '$$$/Dialogs/FieldProps/Barcode/Security/CertInfoLabel', align_children: align_left, width: gClusterWidth, height: gClusterHeight)
		{
			view(align_children: align_row)
			{
				static_text(name: '$$$/Dialogs/FieldProps/Barcode/Security/Cert/Subject', width: gPropColumnWidth);
				static_text(item_id: 'cpsb', width: gClusterWidth - gPropColumnWidth);
			}
			view(align_children: align_row)
			{
				static_text(name: '$$$/Dialogs/FieldProps/Barcode/Security/Cert/Issuer', width: gPropColumnWidth);
				static_text(item_id: 'cpis', width: gClusterWidth - gPropColumnWidth);
			}
			view(align_children: align_row)
			{
				static_text(name: '$$$/Dialogs/FieldProps/Barcode/Security/Cert/ValidFrom', width: gPropColumnWidth);
				static_text(item_id: 'cpvf', width: gClusterWidth - gPropColumnWidth);
			}
			view(align_children: align_row)
			{
				static_text(name: '$$$/Dialogs/FieldProps/Barcode/Security/Cert/ValidTo', width: gPropColumnWidth);
				static_text(item_id: 'cpvt', width: gClusterWidth - gPropColumnWidth);
			}
			button(item_id: 'cdtl', name: '$$$/Dialogs/FieldProps/Barcode/Security/CertDetails', align: align_right);
		}
		button(item_id: 'impf', name: '$$$/Dialogs/FieldProps/Barcode/Security/ImportFile', align: align_right);
		view(align_children: align_row)
		{
			button(item_id: 'brws', name: '$$$/Dialogs/FieldProps/Barcode/Security/BrowseCert', align: align_right);
			button(item_id: 'srch', name: '$$$/Dialogs/FieldProps/Barcode/Security/SearchCert', align: align_right);
		}
    }
}
