~ubuntu-branches/ubuntu/precise/glom/precise-updates

« back to all changes in this revision

Viewing changes to glom/mode_design/layout/layout_item_dialogs/box_formatting.h

  • Committer: Bazaar Package Importer
  • Author(s): Chris Coulson
  • Date: 2009-10-09 16:50:36 UTC
  • mfrom: (1.1.42 upstream)
  • Revision ID: james.westby@ubuntu.com-20091009165036-orinvwmohk838xxl
Tags: 1.12.2-0ubuntu1
* New upstream version:
  - FFE LP: #391664
* debian/control:
  - Bump python-gnome2-extras-dev build-dep to >= 2.25.3.
  - Bump libgdamm3.0-dev build-dep to libgdamm4.0-dev >= 3.99.14.
  - Change libgda3-dev build-dep to libgda-4.0-dev.
  - Change libgda3-postgres dependency to libgda-4.0-postgres.
  - Bump libgtkmm-2.4-dev build-dep to >= 2.14.
  - Add build-dep on libgconfmm-2.6-dev.
  - Bump libgoocanvasmm-dev build-dep to >= 0.14.0.
  - Remove build-dep on libbakery-2.6-dev.
  - Bump postgresql-8.3 dependency to postgresql-8.4.
  - Change scrollkeeper build-dep to rarian-compat.
  - Rename libglom{0,-dev} -> libglom-1.12-{0,dev}. Upstream include
    APIVER in the library name now.
* debian/rules:
  - Update --with-postgres-utils configure flag to point to the new
    path.
  - Drop deprecated --disable-scrollkeeper configure flag.
  - Update DEB_SHLIBDEPS_INCLUDE with new libglom-1.12-0 package name.
  - Don't include /usr/share/cdbs/1/rules/simple-patchsys.mk - there
    are currently no patches.
* debian/libglom-1.12-0.install:
  - Updated for new version.
* debian/libglom-1.12-dev.install:
  - Install pc and header files.
* debian/glom-doc.install:
  - Updated for new version.
* debian/glom.install:
  - Updated for new version.
* Fix debian/watch.
* Dropped obsolete 10-distro-install-postgres-change.patch.
* Built against latest libgoocanvasmm (LP: #428445).
* Also closes LP: #230007, LP: #393229, LP: #393231, LP: #394507,
  LP: #394887, LP: #394894, LP: #397409, LP: #381563.

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/* Glom
 
2
 *
 
3
 * Copyright (C) 2001-2004 Murray Cumming
 
4
 *
 
5
 * This program is free software; you can redistribute it and/or
 
6
 * modify it under the terms of the GNU General Public License as
 
7
 * published by the Free Software Foundation; either version 2 of the
 
8
 * License, or (at your option) any later version.
 
9
 *
 
10
 * This program is distributed in the hope that it will be useful, but
 
11
 * WITHOUT ANY WARRANTY; without even the implied warranty of
 
12
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
 
13
 * General Public License for more details.
 
14
 *
 
15
 * You should have received a copy of the GNU General Public
 
16
 * License along with this program; if not, write to the
 
17
 * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
 
18
 * Boston, MA 02111-1307, USA.
 
19
 */
 
20
 
 
21
#ifndef GLOM_BOX_FORMATTING_H
 
22
#define GLOM_BOX_FORMATTING_H
 
23
 
 
24
#include <gtkmm.h>
 
25
#include <glom/utility_widgets/dialog_properties.h>
 
26
#include <libglom/document/document.h>
 
27
#include <glom/box_withbuttons.h>
 
28
#include <glom/mode_design/comboentry_currency.h>
 
29
#include <glom/mode_design/layout/combobox_relationship.h>
 
30
#include <glom/mode_design/layout/combobox_fields.h>
 
31
 
 
32
namespace Glom
 
33
{
 
34
 
 
35
class Box_Formatting
 
36
 : public Gtk::VBox,
 
37
   public Base_DB
 
38
{
 
39
public:
 
40
  Box_Formatting(BaseObjectType* cobject, const Glib::RefPtr<Gtk::Builder>& builder);
 
41
  virtual ~Box_Formatting();
 
42
 
 
43
  /**
 
44
   * @param format The starting information.
 
45
   */
 
46
  void set_formatting(const FieldFormatting& format);
 
47
  
 
48
  /**
 
49
   * @param format The starting information.
 
50
   * @param table_name The field's table.
 
51
   * @param The field that will have this formatting, so we know what formatting options to allow.
 
52
   */
 
53
  void set_formatting(const FieldFormatting& format, const Glib::ustring& table_name, const sharedptr<const Field>& field);
 
54
  bool get_formatting(FieldFormatting& format) const;
 
55
 
 
56
  //When used for print layout items, 
 
57
  //we hide some stuff:
 
58
  void set_is_for_print_layout();
 
59
 
 
60
private:
 
61
  //Signal handlers:
 
62
  void on_combo_choices_relationship_changed();
 
63
  void on_checkbox();
 
64
 
 
65
  void enforce_constraints();
 
66
 
 
67
  Gtk::VBox* m_vbox_numeric_format;
 
68
  Gtk::CheckButton* m_checkbox_format_use_thousands;
 
69
  Gtk::CheckButton* m_checkbox_format_use_decimal_places;
 
70
  Gtk::Entry* m_entry_format_decimal_places;
 
71
  ComboEntry_Currency* m_entry_currency_symbol;
 
72
 
 
73
  Gtk::VBox* m_vbox_text_format;
 
74
  Gtk::CheckButton* m_checkbox_format_text_multiline;
 
75
  Gtk::Label* m_label_format_text_multiline_height;
 
76
  Gtk::SpinButton* m_spinbutton_format_text_multiline_height;
 
77
  Gtk::HBox* m_hbox_font;
 
78
  Gtk::CheckButton* m_checkbox_format_text_font;
 
79
  Gtk::FontButton* m_fontbutton;
 
80
  Gtk::HBox* m_hbox_color_foreground;
 
81
  Gtk::CheckButton* m_checkbox_format_text_color_foreground;
 
82
  Gtk::ColorButton* m_colorbutton_foreground;
 
83
  Gtk::HBox* m_hbox_color_background;
 
84
  Gtk::CheckButton* m_checkbox_format_text_color_background;
 
85
  Gtk::ColorButton* m_colorbutton_background;
 
86
 
 
87
  Gtk::VBox* m_vbox_choices;
 
88
  Gtk::RadioButton* m_radiobutton_choices_custom;
 
89
  Gtk::RadioButton* m_radiobutton_choices_related;
 
90
  Gtk::CheckButton* m_checkbutton_choices_restricted;
 
91
  AddDel_WithButtons* m_adddel_choices_custom;
 
92
  guint m_col_index_custom_choices;
 
93
  ComboBox_Relationship* m_combo_choices_relationship;
 
94
  ComboBox_Fields* m_combo_choices_field;
 
95
  ComboBox_Fields* m_combo_choices_field_second;
 
96
 
 
97
  mutable FieldFormatting m_format;
 
98
 
 
99
  Glib::ustring m_table_name;
 
100
  sharedptr<const Field> m_field;
 
101
 
 
102
  //We show different options when 
 
103
  //showing this on a print layout.
 
104
  bool m_for_print_layout;
 
105
};
 
106
 
 
107
} //namespace Glom
 
108
 
 
109
#endif //GLOM_BOX_FORMATTING_H