aboutsummaryrefslogtreecommitdiff
path: root/dw/ruler.hh
blob: 1f3491bc2718c8a7195fe6591579bd1f1b4f633d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
#ifndef __RULER_HH__
#define __RULER_HH__

#include "core.hh"

namespace dw {

/**
 * \brief Widget for drawing (horizontal) rules.
 *
 * This is really an empty widget, the HTML parser puts a border
 * around it, and drawing is done in dw::core::Widget::drawWidgetBox.
 * The only remarkable point is that the HAS_CONTENT flag is
 * cleared.
 */
class Ruler: public core::Widget
{
protected:
   void sizeRequestImpl (core::Requisition *requisition);
   void getExtremesImpl (core::Extremes *extremes);
   void containerSizeChangedForChildren ();
   bool usesAvailWidth ();
   void draw (core::View *view, core::Rectangle *area);

public:
   Ruler ();

   bool isBlockLevel ();

   core::Iterator *iterator (core::Content::Type mask, bool atEnd);
};

} // namespace dw

#endif // __RULER_HH__