comparison mde/gui/content/ContentText.d @ 59:672b6b162a36

Added very basic (and currently useless) content support.
author Diggory Hardy <diggory.hardy@gmail.com>
date Sat, 14 Jun 2008 17:52:22 +0100
parents
children
comparison
equal deleted inserted replaced
58:d43523ed4b62 59:672b6b162a36
1 /* LICENSE BLOCK
2 Part of mde: a Modular D game-oriented Engine
3 Copyright © 2007-2008 Diggory Hardy
4
5 This program is free software: you can redistribute it and/or modify it under the terms
6 of the GNU General Public License as published by the Free Software Foundation, either
7 version 2 of the License, or (at your option) any later version.
8
9 This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
10 without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
11 See the GNU General Public License for more details.
12
13 You should have received a copy of the GNU General Public License
14 along with this program. If not, see <http://www.gnu.org/licenses/>. */
15
16 /** The content system − text.
17 */
18 module mde.gui.content.ContentText;
19
20 /** Text content. */
21 /* May end up extending a universal content type.
22 * Services like copy/paste could work on universal content.
23 *
24 * NOTE: Needs to be a reference type really.
25 * Could alternately be:
26 * alias ContentTextStruct* ContentText
27 * where ContentTextStruct is a struct. */
28 class ContentText /+ : Content +/
29 {
30
31 /// Get the text.
32 char[] text () {
33 return text_;
34 }
35
36 protected:
37 //NOTE: need to allow cache-invalidating when text changes!
38 const char[] text_ = "\"a@b\" − an example";
39 }