~registry/gcalctool/trunk

« back to all changes in this revision

Viewing changes to src/math-buttons.h

  • Committer: Robert Ancell
  • Date: 2012-10-14 03:31:40 UTC
  • Revision ID: git-v1:12ba2c81b0a81bb3ac776d1034a3c41b3173196a
Port to Vala

https://bugzilla.gnome.org/show_bug.cgi?id=640685

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
/*
2
 
 * Copyright (C) 2008-2011 Robert Ancell
3
 
 *
4
 
 * This program is free software: you can redistribute it and/or modify it under
5
 
 * the terms of the GNU General Public License as published by the Free Software
6
 
 * Foundation, either version 2 of the License, or (at your option) any later
7
 
 * version. See http://www.gnu.org/copyleft/gpl.html the full text of the
8
 
 * license.
9
 
 */
10
 
 
11
 
#ifndef MATH_BUTTONS_H
12
 
#define MATH_BUTTONS_H
13
 
 
14
 
#include <glib-object.h>
15
 
#include <gtk/gtk.h>
16
 
#include "math-equation.h"
17
 
 
18
 
G_BEGIN_DECLS
19
 
 
20
 
#define MATH_BUTTONS(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), math_buttons_get_type(), MathButtons))
21
 
 
22
 
typedef struct MathButtonsPrivate MathButtonsPrivate;
23
 
 
24
 
typedef struct
25
 
{
26
 
    GtkVBox parent_instance;
27
 
    MathButtonsPrivate *priv;
28
 
} MathButtons;
29
 
 
30
 
typedef struct
31
 
{
32
 
    GtkVBoxClass parent_class;
33
 
} MathButtonsClass;
34
 
 
35
 
typedef enum {
36
 
    BASIC,
37
 
    ADVANCED,
38
 
    FINANCIAL,
39
 
    PROGRAMMING
40
 
} ButtonMode;
41
 
 
42
 
GType math_buttons_get_type(void);
43
 
 
44
 
MathButtons *math_buttons_new(MathEquation *equation);
45
 
 
46
 
void math_buttons_set_mode(MathButtons *buttons, ButtonMode mode);
47
 
 
48
 
ButtonMode math_buttons_get_mode(MathButtons *buttons);
49
 
 
50
 
void math_buttons_set_programming_base(MathButtons *buttons, gint base);
51
 
 
52
 
gint math_buttons_get_programming_base(MathButtons *buttons);
53
 
 
54
 
G_END_DECLS
55
 
 
56
 
#endif /* MATH_BUTTONS_H */