~ubuntu-branches/ubuntu/quantal/gimp/quantal-updates

« back to all changes in this revision

Viewing changes to app/widgets/gimpwidgets-constructors.c

  • Committer: Package Import Robot
  • Author(s): Micah Gersten
  • Date: 2012-05-20 19:21:01 UTC
  • mfrom: (1.1.26) (0.4.16 sid)
  • Revision ID: package-import@ubuntu.com-20120520192101-bs7zetx8ffoq2nfv
Tags: 2.8.0-2ubuntu1
* Merge from Debian unstable (LP: #908472). Remaining Changes:
  - debian/patches/02_help-message.patch,
    debian/patches/03_gimp.desktop.in.in.patch:
    + Update some strings for Ubuntu
  - debian/control:
    + Update description
  - debian/rules:
    + Set gettext domain and update translation templates
* Drop the following patches that were applied upstream:
  - debian/patches/ghost-cursor.patch: fix Wacom tablet cursor events
  - debian/patches/embed-page-setup-dialog.patch

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
1
/* GIMP - The GNU Image Manipulation Program
2
2
 * Copyright (C) 1995-1999 Spencer Kimball and Peter Mattis
3
3
 *
4
 
 * This program is free software; you can redistribute it and/or modify
 
4
 * This program is free software: you can redistribute it and/or modify
5
5
 * it under the terms of the GNU General Public License as published by
6
 
 * the Free Software Foundation; either version 2 of the License, or
 
6
 * the Free Software Foundation; either version 3 of the License, or
7
7
 * (at your option) any later version.
8
8
 *
9
9
 * This program is distributed in the hope that it will be useful,
12
12
 * GNU General Public License for more details.
13
13
 *
14
14
 * You should have received a copy of the GNU General Public License
15
 
 * along with this program; if not, write to the Free Software
16
 
 * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
 
15
 * along with this program.  If not, see <http://www.gnu.org/licenses/>.
17
16
 */
18
17
 
19
18
#include "config.h"
107
106
                                           GIMP_NORMAL_MODE,
108
107
                                           GIMP_DISSOLVE_MODE,
109
108
 
110
 
                                           GIMP_MULTIPLY_MODE,
111
 
                                           GIMP_DIVIDE_MODE,
 
109
                                           GIMP_LIGHTEN_ONLY_MODE,
112
110
                                           GIMP_SCREEN_MODE,
113
 
                                           GIMP_OVERLAY_MODE,
114
 
 
115
111
                                           GIMP_DODGE_MODE,
 
112
                                           GIMP_ADDITION_MODE,
 
113
 
 
114
                                           GIMP_DARKEN_ONLY_MODE,
 
115
                                           GIMP_MULTIPLY_MODE,
116
116
                                           GIMP_BURN_MODE,
 
117
 
 
118
                                           GIMP_OVERLAY_MODE,
 
119
                                           GIMP_SOFTLIGHT_MODE,
117
120
                                           GIMP_HARDLIGHT_MODE,
118
 
                                           GIMP_SOFTLIGHT_MODE,
 
121
 
 
122
                                           GIMP_DIFFERENCE_MODE,
 
123
                                           GIMP_SUBTRACT_MODE,
119
124
                                           GIMP_GRAIN_EXTRACT_MODE,
120
125
                                           GIMP_GRAIN_MERGE_MODE,
121
 
 
122
 
                                           GIMP_DIFFERENCE_MODE,
123
 
                                           GIMP_ADDITION_MODE,
124
 
                                           GIMP_SUBTRACT_MODE,
125
 
                                           GIMP_DARKEN_ONLY_MODE,
126
 
                                           GIMP_LIGHTEN_ONLY_MODE,
 
126
                                           GIMP_DIVIDE_MODE,
127
127
 
128
128
                                           GIMP_HUE_MODE,
129
129
                                           GIMP_SATURATION_MODE,
132
132
 
133
133
  gimp_int_store_insert_separator_after (GIMP_INT_STORE (store),
134
134
                                         GIMP_DISSOLVE_MODE, -1);
135
 
  gimp_int_store_insert_separator_after (GIMP_INT_STORE (store),
136
 
                                         GIMP_OVERLAY_MODE, -1);
137
 
  gimp_int_store_insert_separator_after (GIMP_INT_STORE (store),
138
 
                                         GIMP_GRAIN_MERGE_MODE, -1);
139
 
  gimp_int_store_insert_separator_after (GIMP_INT_STORE (store),
140
 
                                         GIMP_LIGHTEN_ONLY_MODE, -1);
 
135
 
 
136
  gimp_int_store_insert_separator_after (GIMP_INT_STORE (store),
 
137
                                         GIMP_ADDITION_MODE, -1);
 
138
 
 
139
  gimp_int_store_insert_separator_after (GIMP_INT_STORE (store),
 
140
                                         GIMP_BURN_MODE, -1);
 
141
 
 
142
  gimp_int_store_insert_separator_after (GIMP_INT_STORE (store),
 
143
                                         GIMP_HARDLIGHT_MODE, -1);
 
144
 
 
145
  gimp_int_store_insert_separator_after (GIMP_INT_STORE (store),
 
146
                                         GIMP_DIVIDE_MODE, -1);
141
147
 
142
148
  if (with_behind_mode)
143
149
    {
178
184
                       const gchar *label)
179
185
{
180
186
  GtkWidget *button;
181
 
  GtkWidget *hbox;
182
187
  GtkWidget *image;
183
 
  GtkWidget *lab;
184
188
 
185
189
  button = gtk_button_new ();
186
190
 
187
 
  hbox = gtk_hbox_new (FALSE, 6);
188
 
  gtk_container_add (GTK_CONTAINER (button), hbox);
189
 
  gtk_widget_show (hbox);
190
 
 
191
 
  image = gtk_image_new_from_stock (stock_id, GTK_ICON_SIZE_BUTTON);
192
 
  gtk_box_pack_start (GTK_BOX (hbox), image, FALSE, FALSE, 0);
193
 
  gtk_widget_show (image);
194
 
 
195
 
  lab = gtk_label_new_with_mnemonic (label);
196
 
  gtk_label_set_mnemonic_widget (GTK_LABEL (lab), button);
197
 
  gtk_box_pack_start (GTK_BOX (hbox), lab, TRUE, TRUE, 0);
198
 
  gtk_widget_show (lab);
 
191
  if (label)
 
192
    {
 
193
      GtkWidget *hbox;
 
194
      GtkWidget *lab;
 
195
 
 
196
      hbox = gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 6);
 
197
      gtk_container_add (GTK_CONTAINER (button), hbox);
 
198
      gtk_widget_show (hbox);
 
199
 
 
200
      image = gtk_image_new_from_stock (stock_id, GTK_ICON_SIZE_BUTTON);
 
201
      gtk_box_pack_start (GTK_BOX (hbox), image, FALSE, FALSE, 0);
 
202
      gtk_widget_show (image);
 
203
 
 
204
      lab = gtk_label_new_with_mnemonic (label);
 
205
      gtk_label_set_mnemonic_widget (GTK_LABEL (lab), button);
 
206
      gtk_box_pack_start (GTK_BOX (hbox), lab, TRUE, TRUE, 0);
 
207
      gtk_widget_show (lab);
 
208
    }
 
209
  else
 
210
    {
 
211
      image = gtk_image_new_from_stock (stock_id, GTK_ICON_SIZE_BUTTON);
 
212
      gtk_container_add (GTK_CONTAINER (button), image);
 
213
      gtk_widget_show (image);
 
214
    }
199
215
 
200
216
  return button;
201
217
}