// This may look like C code, but it's really -*- C++ -*-
/*
 * Copyright (C) 2008 Emweb bvba, Kessel-Lo, Belgium.
 *
 * See the LICENSE file for terms of use.
 */
#ifndef EXT_TOOLTIP_CONFIG_H_
#define EXT_TOOLTIP_CONFIG_H_

#include <Wt/WObject>

namespace Wt {
  namespace Ext {

class Menu;

/*! \class ToolTipConfig Wt/Ext/ToolTipConfig Wt/Ext/ToolTipConfig
 *  \brief A configuration object for tool tips.
 *
 * \sa AbstractButton::configureToolTip()
 *
 * \ingroup ext
 */
class ToolTipConfig : public WObject
{
public:
  /*! \brief Create a default tool tip configuration object.
   */
  ToolTipConfig(WObject *parent = 0);

  /*! \brief Option to dismiss the tool tip automatically after a
   *         fixed period.
   *
   * The default value is <i>true</i>.
   */
  bool autoDismiss;

  /*! \brief Option to hide the tool tip when the mouse moves away.
   *
   * The default value is <i>true</i>.
   */
  bool autoHide;

  /*! \brief Delay (in milliseconds) to dismiss the tool tip.
   *
   * The default value is 5000.
   *
   * \sa autoDismiss
   */
  int  dismissDelay;

  /*! \brief Delay (in milliseconds) to hide the tool tip.
   *
   * The default value is 200.
   *
   * \sa autoHide
   */
  int  hideDelay;

  /*! \brief Delay (in milliseconds) to show the tool tip.
   *
   * The default value is 500.
   */
  int  showDelay;

  /*! \brief Option to use animations.
   *
   * The default value is <i>false</i>.
   */
  bool animate;

  /*! \brief Option to hide when the user clicks anywhere.
   *
   * The default value is <i>true</i>.
   */
  bool hideOnClick;

  /*! \brief Maximum tool tip width (pixels).
   *
   * The default value is 300.
   */
  int  maxWidth;

  /*! \brief Minimum tool tip width (pixels).
   *
   * The default value is 40.
   */
  int  minWidth;

  /*! \brief Option to track the mouse.
   *
   * The default value is <i>false</i>
   */
  bool trackMouse;

  void createConfig(std::ostream& config);
};

  }
}

#endif // EXT_TOOLTIP_CONFIG_H_
