Planeshift
pawsconfigchatbubbles.h
Go to the documentation of this file.
1 /*
2  * pawsconfigchatbubbles.h - Author: Steven Patrick
3  *
4  * Copyright (C) 2001-2008 Atomic Blue (info@planeshift.it, http://www.atomicblue.org)
5  *
6  *
7  * This program is free software; you can redistribute it and/or
8  * modify it under the terms of the GNU General Public License
9  * as published by the Free Software Foundation (version 2 of the License)
10  * This program is distributed in the hope that it will be useful,
11  * but WITHOUT ANY WARRANTY; without even the implied warranty of
12  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13  * GNU General Public License for more details.
14  * You should have received a copy of the GNU General Public License
15  * along with this program; if not, write to the Free Software
16  * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
17  *
18  */
19 
20 #ifndef PAWS_CONFIG_CHATBUBBLES_HEADER
21 #define PAWS_CONFIG_CHATBUBBLES_HEADER
22 
23 // PAWS INCLUDES
24 #include "paws/pawswidget.h"
25 #include "pawsconfigwindow.h"
26 
27 class psChatBubbles;
28 class pawsCheckBox;
29 class pawsEditTextBox;
30 class pawsScrollBar;
31 class pawsTextBox;
32 class pawsComboBox;
33 
35 {
36  int chatType;
37  csString type;
39 
45 
55 
57 };
58 
63 {
64 public:
66  void drawFrame();
67 
68  //from pawsWidget:
69  virtual bool PostSetup();
70 
71  // from pawsConfigSectionWindow:
72  virtual bool Initialize();
73  virtual bool LoadConfig();
74  virtual bool SaveConfig();
75  virtual void SetDefault();
76  virtual void Show();
77 
78  // from pawsWidget
79  bool OnChange(pawsWidget* /*widget*/) { dirty = true; return true; }
80  virtual bool OnButtonPressed(int /*button*/, int /*keyModifier*/, pawsWidget* /*widget*/)
81  {
82  dirty = true;
83  return true;
84  }
85  bool OnMouseDown(int button, int modifiers, int x, int y );
86  bool OnScroll( int direction, pawsScrollBar* widget );
87  virtual void OnListAction( pawsListBox* selected, int status );
88 
89 private:
90  psChatBubbles *chatBubbles;
91 
92  pawsCheckBox *allEnabled;
93 
94  csArray<pawsBubbleChatType> pawsBubbleChatTypes;
95 
96  pawsTextBox *maxLineLenText;
97  pawsEditTextBox *maxLineLen;
98  pawsTextBox *shortPhraseCharCountText;
99  pawsEditTextBox *shortPhraseCharCount;
100  pawsTextBox *longPhraseLineCountText;
101  pawsEditTextBox *longPhraseLineCount;
102 
103  pawsScrollBar *scrollBar;
104  pawsCheckBox *mixActionColours;
105 };
106 
108 #endif
pawsEditTextBox * TextR
The main base widget that all other widgets should inherit from.
Definition: pawswidget.h:116
pawsEditTextBox * TextG
Creates the effect of a chat bubble on top of character heads taking data from text chat...
Definition: chatbubbles.h:54
A combination widget that has a check box and a text label.
Definition: pawscheckbox.h:48
configuration screen for chat bubbles
An edit box widget/.
Definition: pawstextbox.h:409
pawsEditTextBox * TextB
pawsEditTextBox * OutlineR
CREATE_PAWS_FACTORY(pawsConfigChatBubbles)
virtual bool OnButtonPressed(int, int, pawsWidget *)
Called whenever a button is pressed.
bool OnChange(pawsWidget *)
Called whenever a widget is selected.
A simple list box widget.
Definition: pawslistbox.h:202
A simple scroll bar widget.
Definition: pawscrollbar.h:64
pawsEditTextBox * OutlineB
void void Initialize(iObjectRegistry *object_reg)
pawsEditTextBox * ShadowB
A basic combo box widget.
Definition: pawscombo.h:53
pawsEditTextBox * OutlineG
pawsEditTextBox * ShadowG
pawsEditTextBox * ShadowR
A basic text box widget.
Definition: pawstextbox.h:42