tcp: Fix 64 bit build with debugging features enabled.
[haiku.git] / src / kits / interface / textview_support / InlineInput.h
blobbca5772cf610a195d19a6154d211d1bcbe752259
1 /*
2 * Copyright 2003-2006, Haiku, Inc. All Rights Reserved.
3 * Distributed under the terms of the MIT License.
5 * Authors:
6 * Stefano Ceccherini (burton666@libero.it)
7 */
9 #ifndef __INLINEINPUT_H
10 #define __INLINEINPUT_H
12 #include <Messenger.h>
13 #include <TextView.h>
15 struct clause;
17 class BTextView::InlineInput {
18 public:
19 InlineInput(BMessenger);
20 ~InlineInput();
22 const BMessenger *Method() const;
24 bool IsActive() const;
25 void SetActive(bool active);
27 int32 Length() const;
28 void SetLength(int32 length);
30 int32 Offset() const;
31 void SetOffset(int32 offset);
33 int32 SelectionLength() const;
34 void SetSelectionLength(int32);
36 int32 SelectionOffset() const;
37 void SetSelectionOffset(int32 offset);
39 bool AddClause(int32, int32);
40 bool GetClause(int32 index, int32 *start, int32 *end) const;
41 int32 CountClauses() const;
43 void ResetClauses();
45 private:
46 const BMessenger fMessenger;
48 bool fActive;
50 int32 fOffset;
51 int32 fLength;
53 int32 fSelectionOffset;
54 int32 fSelectionLength;
56 int32 fNumClauses;
57 clause *fClauses;
60 #endif //__INLINEINPUT_H