File: dasher_editor_private.h

package info (click to toggle)
dasher 5.0.0~beta~repack2-2
  • links: PTS, VCS
  • area: main
  • in suites: bullseye
  • size: 70,872 kB
  • sloc: xml: 181,314; cpp: 70,860; java: 8,020; python: 3,579; makefile: 939; sh: 324; ansic: 223; perl: 71
file content (45 lines) | stat: -rw-r--r-- 1,356 bytes parent folder | download | duplicates (5)
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
#ifndef DASHER_EDITOR_PRIVATE_H
#define DASHER_EDITOR_PRIVATE_H

#include <gtk/gtk.h>

// Forward declarations
class DasherAppSettings;
typedef struct _GtkDasherControl GtkDasherControl;
struct _GtkDasherControl;
typedef struct _DasherEditorExternalPrivate DasherEditorExternalPrivate;
struct _DasherEditorExternalPrivate;

typedef struct _DasherEditorPrivate DasherEditorPrivate;

struct _DasherEditorPrivate {
  GtkDasherControl *pDasherCtrl;
  GtkTextView *pTextView;
  GtkTextBuffer *pBuffer;
  GtkClipboard *pTextClipboard;
  GtkClipboard *pPrimarySelection;
  GtkTextMark *pNewMark;
  DasherAppSettings *pAppSettings;
  gchar *szFilename;
  gboolean bFileModified; // TODO: Make this work properly, export to main for quit etc

  // for conversion mode:
  GtkTextTag *pOutputTag;
  GtkTextTag *pHiddenTag;
  GtkTextTag *pVisibleTag;
  gboolean bConversionMode;
  gint iLastOffset;
  gint iCurrentState; // 0 = unconverted, 1 = converted

  // for direct mode:
  DasherEditorExternalPrivate *pExtPrivate;

  //Paralleling the previous approach in dasher_main, we _don't_ send context_changed
  // events if we're in the middle of executing a control action (as this would rebuild
  // the canvas)
  gboolean bInControlAction;
};

#define DASHER_EDITOR_GET_PRIVATE(o) (G_TYPE_INSTANCE_GET_PRIVATE((o), DASHER_TYPE_EDITOR, DasherEditorPrivate))

#endif