from xml from json
<item
	id           = "new"		// required, will generated automatically if empty
	type         = "buttonSelect"	// required, item type
	img          = "new.gif"	// optional, icon for enabled item
	imgdis       = "new_dis.gif"	// optional, icon for disabled image
	text         = "New"		// optional, item text
	title        = "Tooltip here"	// optional, tooltip for item
	enabled      = "false"		// optional, disable item
	hidden       = "true"		// optional, hide item
	action       = "function_name"	// optional, function name to exec on click
	openAll      = "true"		// optional, open sublevel by clicking icon also
	renderSelect = "false"		// optional, do not show selection in sublevel
	mode         = "select"		// optional, working in select mode
	width        = "70"		// optional, static button width, useful in select mode
	maxOpen      = "5"		// optional, count of visible sublevel items
	selected     = "subitem_id"	// optional, preselect item for "select" mode
>
	// optional, userdata
	<userdata name="p1">value1</userdata>
	<userdata name="p2">value2</userdata>
	
	// list of subitems
	<item
		id       = "new_text"		// required, will generated automatically if empty
		type     = "button"		// required, item type for button
		img      = "text_document.gif"	// optional, icon for both enabled/disabled item
		text     = "Text Document"	// optional, item text
		enabled  = "false"		// optional, disable item
		action   = "function_name"	// optional, function name to exec on click
	>
		<itemText>
			Text Document		// optional, alternate text for item
		</itemText>
	</item>
	<item
		id       = "new_text"		// required, will generated automatically if empty
		type     = "separator"		// required, item type for separator
	/>
</item>
{
	id:           "new"		// required, will generated automatically if empty
	type:         "buttonSelect"	// required, item type
	img:          "new.gif"		// optional, icon for enabled item
	imgdis:       "new_dis.gif"	// optional, icon for disabled image
	text:         "New"		// optional, item text
	title:        "Tooltip here"	// optional, tooltip for item
	enabled:      false		// optional, disable item
	hidden:       true		// optional, hide item
	action:       "function_name"	// optional, function name to exec on click
	openAll:      true		// optional, open sublevel by clicking icon also
	renderSelect: false		// optional, do not show selection in sublevel
	mode:         "select"		// optional, working in select mode
	width:        70		// optional, static button width, useful in select mode
	maxOpen:      5			// optional, count of visible sublevel items
	selected:     "subitem_id"	// optional, preselect item for "select" mode
	userdata: {			// optional, userdata
		p1: "value1"		// userdara, name:value pairs
		p2: "value2"
	}
	options: [{				// list of subitems
		id:      "new_text"		// required, will generated automatically if empty
		type:    "button"		// required, item type for button
		img:     "text_document.gif"	// optional, icon for both enabled/disabled item
		text:    "Text Document"	// optional, item text
		enabled: false			// optional, disable item
		action:  "function_name"	// optional, function name to exec on click
		userdata: {			// optional, userdata
			p1: "value1"		// userdara, name:value pairs
			p2: "value2"
		}
	},{
		id:   "sep_id"		// required, will generated automatically if empty
		type: "separator"	// required, item type for separator
	}]
	
	// deprecated:
	
	img_disabled: "open_dis.gif"	// => imgdis:  "open_dis.gif"
	disabled:     true		// => enabled: false
	options: [{
		type: "obj"		// => type: "button"
		type: "sep"		// => type: "separator"
	}]
	
}
The purpose of this demo is to show you list of available xml and json attributes in action