#ifndef _TK_COMPOUND_OPTION_H_
#define _TK_COMPOUND_OPTION_H_

#include "tk_enumoption.h"
#include <string>

using namespace std;

/**
 * \brief Specifies whether the widget should display both an image and text.
 *
 * If so, where the image should be placed relative to the text. Valid values for this option are bottom, center, left, none, right and top. The default value is none, meaning that the button will display either an image or text, depending on the values of the image and bitmap options. 
 * Valid for button, label, menu, menubutton, text widgets.
 * 
 * \date 01-13-2006
 *
 * \author Ondrej Svejdar
 *
 * \todo 
 *
 * \bug 
 *
 */
class TkCompoundOption:public TkEnumOption
{
public:

	/**
	 * factory 
	 * \return 
	 */
	static TXmlObject* newObject()
	{
		return new TkCompoundOption(0);
	}

	static const char* E_BOTTOM;
	static const char* E_CENTER;
	static const char* E_LEFT;
	static const char* E_NONE;
	static const char* E_RIGHT;
	static const char* E_TOP;

	static const char* type;
	static const char* enums[];

	/// C++ representation of this enumeration
	typedef enum opts
	{
		/// image placed on the bottom of the text
		bottom	=0,
		/// image placed in the center of the text
		center	=1,
		/// image placed on the left of the text
		left	=2,
		/// only image or only text will be displayed
		none	=3,
		/// image placed on the right of the text
		right	=4,
		/// image placed on the top of the text
		top		=5
	};

	const char* getType() const;

	/**
	 * ctor
	 * \param value One of following : "bottom","center","left","none","right","top"
	 * or you can use static const members of TkCompoundOption :
	 * E_BOTTOM, E_CENTER, E_LEFT, E_NONE, E_RIGHT, E_TOP
	 */
	inline TkCompoundOption(const char* value):TkEnumOption(value,enums)
	{
	}

	/**
	 * ctor, use this constructor if you can, because it is faster
	 * \param value One of following : bottom, center, left, none, right, top
	 */
	inline TkCompoundOption(opts value):TkEnumOption((int)value,enums)
	{
	}
};

#endif/*_TK_COMPOUND_OPTION_H_*/
