File: hk_label.h

package info (click to toggle)
hk-classes 0.8.2-2
  • links: PTS
  • area: main
  • in suites: etch, etch-m68k
  • size: 10,872 kB
  • ctags: 16,819
  • sloc: cpp: 90,990; ansic: 78,016; sh: 8,385; python: 3,793; makefile: 292
file content (102 lines) | stat: -rw-r--r-- 3,214 bytes parent folder | download | duplicates (2)
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
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
// ****************************************************************************
// copyright (c) 2000-2005 Horst Knorr <hk_classes@knoda.org>
// This file is part of the hk_classes library.
// This file may be distributed and/or modified under the terms of the
// GNU Library Public License version 2 as published by the Free Software
// Foundation and appearing in the file COPYING included in the
// packaging of this file.
// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
// ****************************************************************************
#ifndef HK_LABEL
#define HK_LABEL
#include "hk_visible.h"
#include "hk_form.h"
using namespace std;
class hk_labelmodeprivate;
/**
 *
 *@short  base class for labels in forms
 *@version $Revision: 1.11 $
 *@author Horst Knorr (hk_classes@knoda.org)
 *
 *base class for labels in forms
 */
class hk_label:public hk_visible
{
    public:
        hk_label(hk_form* form=NULL);
	virtual ~hk_label();
	/**
 *if true a line should be painted above the data
 *
 *See @ref set_configurefunction  for details
 *
 */
        void    set_topline(int l=1,bool registerchange=true);
/**
 *if true a line should be painted under the data
 *
 *See @ref set_configurefunction  for details
 */
        void    set_bottomline(int l=1,bool registerchange=true);
/**
 *if true a line should be painted left of the data
 *
 *See @ref set_configurefunction  for details
 */

        void    set_leftline(int l=1,bool registerchange=true);
/**
 *if true a line should be painted right the data
 *
 *See @ref set_configurefunction  for details
 */

        void    set_rightline(int l=1,bool registerchange=true);
/**
 *if true a diagonal should be painted from _l_inks _u_nten to _r_echts _o_ben
 * (left down to right up)
 *
 *See @ref set_configurefunction  for details
 */

        void    set_diagonalluro(int l=1,bool registerchange=true);
/**
 *if true a diagonal should be painted from _l_inks _o_ben to _r_echts _u_nten
 * (left top to right down)
 *
 *See @ref set_configurefunction  for details
 */
        void    set_diagonalloru(int l=1,bool registerchange=true);
        int    diagonalloru(void);
        int    topline(void);
        int    bottomline(void);
        int    leftline(void);
        int    rightline(void);
        int    diagonalluro(void);
/**
 *if true a frame should be painted around the text (bottomline + topline + leftline + rightline)
 *
 *See @ref set_configurefunction  for details
 */
        void    set_frame(int l=1,bool registerchange=true);

protected:
	virtual bool	presentationmode_changed(void);
        virtual void savedata(ostream& s );
        virtual void loaddata(xmlNodePtr definition);
	virtual void widget_specific_topline_changed(void){}
	virtual void widget_specific_bottomline_changed(void){}
	virtual void widget_specific_leftline_changed(void){}
	virtual void widget_specific_rightline_changed(void){}
	virtual void widget_specific_diagonalluro_changed(void){}
	virtual void widget_specific_diagonalloru_changed(void){}



private:
 	hk_labelmodeprivate* p_designdata;
 	hk_labelmodeprivate* p_viewdata;
};
#endif