File: statline.h

package info (click to toggle)
wxwidgets3.0 3.0.5.1%2Bdfsg-2
  • links: PTS, VCS
  • area: main
  • in suites: bullseye
  • size: 120,464 kB
  • sloc: cpp: 896,633; makefile: 52,303; ansic: 21,971; sh: 5,713; python: 2,940; xml: 1,534; perl: 264; javascript: 33
file content (86 lines) | stat: -rw-r--r-- 2,748 bytes parent folder | download | duplicates (14)
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
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
/////////////////////////////////////////////////////////////////////////////
// Name:        statline.h
// Purpose:     interface of wxStaticLine
// Author:      wxWidgets team
// Licence:     wxWindows licence
/////////////////////////////////////////////////////////////////////////////

/**
    @class wxStaticLine

    A static line is just a line which may be used in a dialog to separate the
    groups of controls.

    The line may be only vertical or horizontal. Moreover, not all ports
    (notably not wxGTK) support specifying the transversal direction of the
    line (e.g. height for a horizontal line) so for maximal portability you
    should specify it as wxDefaultCoord.

    @beginStyleTable
    @style{wxLI_HORIZONTAL}
           Creates a horizontal line.
    @style{wxLI_VERTICAL}
           Creates a vertical line.
    @endStyleTable

    @library{wxcore}
    @category{ctrl}

    @see wxStaticBox
*/
class wxStaticLine : public wxControl
{
public:
    /**
      Default constructor
    */
    wxStaticLine();

    /**
        Constructor, creating and showing a static line.

        @param parent
            Parent window. Must not be @NULL.
        @param id
            Window identifier. The value wxID_ANY indicates a default value.
        @param pos
            Window position.
            If ::wxDefaultPosition is specified then a default position is chosen.
        @param size
            Size. Note that either the height or the width (depending on
            whether the line if horizontal or vertical) is ignored.
        @param style
            Window style (either wxLI_HORIZONTAL or wxLI_VERTICAL).
        @param name
            Window name.

        @see Create()
    */
    wxStaticLine(wxWindow* parent, wxWindowID id = wxID_ANY,
                 const wxPoint& pos = wxDefaultPosition,
                 const wxSize& size = wxDefaultSize,
                 long style = wxLI_HORIZONTAL,
                 const wxString& name = wxStaticLineNameStr);

    /**
        Creates the static line for two-step construction.
        See wxStaticLine() for further details.
    */
    bool Create(wxWindow* parent, wxWindowID id = wxID_ANY,
                const wxPoint& pos = wxDefaultPosition,
                const wxSize& size = wxDefaultSize, long style = wxLI_HORIZONTAL,
                const wxString& name = wxStaticLineNameStr);

    /**
        This static function returns the size which will be given to the smaller
        dimension of the static line, i.e. its height for a horizontal line or its
        width for a vertical one.
    */
    static int GetDefaultSize();

    /**
        Returns @true if the line is vertical, @false if horizontal.
    */
    bool IsVertical() const;
};