Commit 950de504 authored by Roman Lebedev's avatar Roman Lebedev

DTGTK label is gone.

FIXME: add CSS!
parent eca90db0
......@@ -74,7 +74,6 @@ FILE(GLOB SOURCE_FILES
"develop/masks/masks.c"
"dtgtk/button.c"
"dtgtk/icon.c"
"dtgtk/label.c"
"dtgtk/gradientslider.c"
"dtgtk/togglebutton.c"
"dtgtk/paint.c"
......
......@@ -33,7 +33,6 @@
#include "dtgtk/button.h"
#include "dtgtk/icon.h"
#include "dtgtk/gradientslider.h"
#include "dtgtk/label.h"
#include <strings.h>
#include <assert.h>
......
/*
This file is part of darktable,
copyright (c)2010 Henrik Andersson.
darktable is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
darktable is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with darktable. If not, see <http://www.gnu.org/licenses/>.
*/
#include <string.h>
#include "common/darktable.h"
#include "gui/gtk.h"
#include "label.h"
#include "bauhaus/bauhaus.h"
static void _label_class_init(GtkDarktableLabelClass *klass);
static void _label_init(GtkDarktableLabel *slider);
static void _label_size_request(GtkWidget *widget, GtkRequisition *requisition);
static void _label_get_preferred_width(GtkWidget *widget, gint *minimal_width, gint *natural_width);
static void _label_get_preferred_height(GtkWidget *widget, gint *minimal_height, gint *natural_height);
static gboolean _label_draw(GtkWidget *widget, cairo_t *cr);
static void _label_class_init(GtkDarktableLabelClass *klass)
{
GtkWidgetClass *widget_class = (GtkWidgetClass *)klass;
widget_class->get_preferred_width = _label_get_preferred_width;
widget_class->get_preferred_height = _label_get_preferred_height;
widget_class->draw = _label_draw;
}
static void _label_init(GtkDarktableLabel *label)
{
}
static void _label_size_request(GtkWidget *widget, GtkRequisition *requisition)
{
g_return_if_fail(widget != NULL);
g_return_if_fail(DTGTK_IS_LABEL(widget));
g_return_if_fail(requisition != NULL);
requisition->width = -1;
requisition->height = DT_PIXEL_APPLY_DPI(17);
}
static void _label_get_preferred_width(GtkWidget *widget, gint *minimal_width, gint *natural_width)
{
GtkRequisition requisition = { 0 };
_label_size_request(widget, &requisition);
*minimal_width = *natural_width = requisition.width;
}
static void _label_get_preferred_height(GtkWidget *widget, gint *minimal_height, gint *natural_height)
{
GtkRequisition requisition = { 0 };
_label_size_request(widget, &requisition);
*minimal_height = *natural_height = requisition.height;
}
static gboolean _label_draw(GtkWidget *widget, cairo_t *cr)
{
g_return_val_if_fail(widget != NULL, FALSE);
g_return_val_if_fail(DTGTK_IS_LABEL(widget), FALSE);
GtkAllocation allocation;
gtk_widget_get_allocation(widget, &allocation);
int x = allocation.x;
int y = allocation.y;
int width = allocation.width;
int height = allocation.height;
// Formatting the display of text and draw it...
PangoLayout *layout;
layout = gtk_widget_create_pango_layout(widget, NULL);
pango_layout_set_font_description(layout, darktable.bauhaus->pango_font_desc);
pango_cairo_context_set_resolution(pango_layout_get_context(layout), darktable.gui->dpi);
const gchar *text = gtk_label_get_text(GTK_LABEL(widget));
pango_layout_set_text(layout, text, -1);
int pw, ph;
pango_layout_get_pixel_size(layout, &pw, &ph);
// Begin cairo drawing
cairo_set_source_rgba(cr, 1, 1, 1, 0.10);
cairo_set_antialias(cr, CAIRO_ANTIALIAS_NONE);
cairo_set_line_width(cr, DT_PIXEL_APPLY_DPI(1.0));
// cairo_set_line_cap(cr,CAIRO_LINE_CAP_ROUND);
if(DTGTK_LABEL(widget)->flags & DARKTABLE_LABEL_UNDERLINED)
{
// TODO: make DPI aware
cairo_move_to(cr, x, y + height - 2);
cairo_line_to(cr, x + width, y + height - 2);
cairo_stroke(cr);
}
else if(DTGTK_LABEL(widget)->flags & DARKTABLE_LABEL_BACKFILLED)
{
// TODO: make DPI aware
cairo_rectangle(cr, x, y, width, height);
cairo_fill(cr);
}
else if(DTGTK_LABEL(widget)->flags & DARKTABLE_LABEL_TAB)
{
float rx = x, rw = pw + DT_PIXEL_APPLY_DPI(2);
// the blocks
if(DTGTK_LABEL(widget)->flags & DARKTABLE_LABEL_ALIGN_RIGHT)
{
rx = x + width - pw - DT_PIXEL_APPLY_DPI(8.0);
cairo_move_to(cr, rx + rw + DT_PIXEL_APPLY_DPI(4.0), y + height - DT_PIXEL_APPLY_DPI(1.0));
cairo_line_to(cr, rx + rw + DT_PIXEL_APPLY_DPI(4.0), y);
cairo_line_to(cr, rx, y);
cairo_line_to(cr, rx - DT_PIXEL_APPLY_DPI(15.0), y + height - DT_PIXEL_APPLY_DPI(1.0));
cairo_close_path(cr);
cairo_fill(cr);
}
else
{
cairo_move_to(cr, rx, y);
cairo_line_to(cr, rx + rw + DT_PIXEL_APPLY_DPI(4.0), y);
cairo_line_to(cr, rx + rw + DT_PIXEL_APPLY_DPI(4.0 + 15.0), y + height - DT_PIXEL_APPLY_DPI(1.0));
cairo_line_to(cr, rx, y + height - DT_PIXEL_APPLY_DPI(1.0));
cairo_close_path(cr);
cairo_fill(cr);
}
// hline
cairo_move_to(cr, x, y + height - DT_PIXEL_APPLY_DPI(0.5));
cairo_line_to(cr, x + width - DT_PIXEL_APPLY_DPI(2.0), y + height - DT_PIXEL_APPLY_DPI(0.5));
cairo_stroke(cr);
}
// draw text
int lx = x + DT_PIXEL_APPLY_DPI(4), ly = y + ((height / 2.0) - (ph / 2.0));
if(DTGTK_LABEL(widget)->flags & DARKTABLE_LABEL_ALIGN_RIGHT)
lx = x + width - pw - DT_PIXEL_APPLY_DPI(6);
else if(DTGTK_LABEL(widget)->flags & DARKTABLE_LABEL_ALIGN_CENTER)
lx = (width / 2.0) - (pw / 2.0);
cairo_move_to(cr, lx, ly);
cairo_set_source_rgba(cr, 1.0, 1.0, 1.0, 0.5);
pango_cairo_show_layout(cr, layout);
g_object_unref(layout);
cairo_set_antialias(cr, CAIRO_ANTIALIAS_DEFAULT);
return FALSE;
}
// Public functions
GtkWidget *dtgtk_label_new(const gchar *text, _darktable_label_flags_t flags)
{
GtkDarktableLabel *label;
label = g_object_new(dtgtk_label_get_type(), NULL);
gtk_label_set_text(GTK_LABEL(label), text);
label->flags = flags;
return (GtkWidget *)label;
}
void dtgtk_label_set_text(GtkDarktableLabel *label, const gchar *text, _darktable_label_flags_t flags)
{
gtk_label_set_text(GTK_LABEL(label), text);
label->flags = flags;
gtk_widget_queue_draw(GTK_WIDGET(label));
}
GType dtgtk_label_get_type()
{
static GType dtgtk_label_type = 0;
if(!dtgtk_label_type)
{
static const GTypeInfo dtgtk_label_info = {
sizeof(GtkDarktableLabelClass), (GBaseInitFunc)NULL, (GBaseFinalizeFunc)NULL,
(GClassInitFunc)_label_class_init, NULL, /* class_finalize */
NULL, /* class_data */
sizeof(GtkDarktableLabel), 0, /* n_preallocs */
(GInstanceInitFunc)_label_init,
};
dtgtk_label_type = g_type_register_static(GTK_TYPE_LABEL, "GtkDarktableLabel", &dtgtk_label_info, 0);
}
return dtgtk_label_type;
}
// modelines: These editor modelines have been set for all relevant files by tools/update_modelines.sh
// vim: shiftwidth=2 expandtab tabstop=2 cindent
// kate: tab-indents: off; indent-width 2; replace-tabs on; indent-mode cstyle; remove-trailing-space on;
/*
This file is part of darktable,
copyright (c) 2010 Henrik Andersson.
darktable is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
darktable is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with darktable. If not, see <http://www.gnu.org/licenses/>.
*/
#ifndef DTGTK_LABEL_H
#define DTGTK_LABEL_H
#include <gtk/gtk.h>
G_BEGIN_DECLS
#define DTGTK_LABEL(obj) G_TYPE_CHECK_INSTANCE_CAST(obj, dtgtk_label_get_type(), GtkDarktableLabel)
#define DTGTK_LABEL_CLASS(klass) GTK_CHECK_CLASS_CAST(klass, dtgtk_label_get_type(), GtkDarktableLabelClass)
#define DTGTK_IS_LABEL(obj) G_TYPE_CHECK_INSTANCE_TYPE(obj, dtgtk_label_get_type())
#define DTGTK_IS_LABEL_CLASS(klass) GTK_CHECK_CLASS_TYPE(obj, dtgtk_label_get_type())
typedef enum _darktable_label_flags
{
DARKTABLE_LABEL_UNDERLINED = 1,
DARKTABLE_LABEL_BACKFILLED = 2,
DARKTABLE_LABEL_TAB = 4,
DARKTABLE_LABEL_ALIGN_LEFT = 16,
DARKTABLE_LABEL_ALIGN_RIGHT = 32,
DARKTABLE_LABEL_ALIGN_CENTER = 64
} _darktable_label_flags_t;
typedef struct _GtkDarktableLabel
{
GtkLabel widget;
gint flags;
} GtkDarktableLabel;
typedef struct _GtkDarktableLabelClass
{
GtkButtonClass parent_class;
} GtkDarktableLabelClass;
GType dtgtk_label_get_type(void);
/** Instansiate a new darktable label control passing paint function as content */
GtkWidget *dtgtk_label_new(const gchar *label, _darktable_label_flags_t flags);
/** set the text of the label */
void dtgtk_label_set_text(GtkDarktableLabel *label, const gchar *text, _darktable_label_flags_t flags);
G_END_DECLS
#endif
// modelines: These editor modelines have been set for all relevant files by tools/update_modelines.sh
// vim: shiftwidth=2 expandtab tabstop=2 cindent
// kate: tab-indents: off; indent-width 2; replace-tabs on; indent-mode cstyle; remove-trailing-space on;
......@@ -26,7 +26,6 @@
#include "common/camera_control.h"
#include "common/utility.h"
#include "dtgtk/button.h"
#include "dtgtk/label.h"
#include "gui/camera_import_dialog.h"
#include <time.h>
......@@ -259,9 +258,7 @@ static void _camera_import_dialog_new(_camera_import_dialog_t *data)
gtk_container_set_border_width(GTK_CONTAINER(data->settings.page), 5);
// general settings
gtk_box_pack_start(GTK_BOX(data->settings.page),
dtgtk_label_new(_("general"), DARKTABLE_LABEL_TAB | DARKTABLE_LABEL_ALIGN_RIGHT), FALSE,
FALSE, 0);
gtk_box_pack_start(GTK_BOX(data->settings.page), gtk_label_new(_("general")), FALSE, FALSE, 0);
// ignoring of jpegs. hack while we don't handle raw+jpeg in the same directories.
data->settings.general.ignore_jpeg = gtk_check_button_new_with_label(_("ignore JPEG files"));
......
......@@ -25,7 +25,6 @@
#include "common/image_cache.h"
#include "develop/develop.h"
#include "develop/imageop.h"
#include "dtgtk/label.h"
#include "dtgtk/button.h"
#include "gui/accelerators.h"
#include "gui/contrast.h"
......
......@@ -17,7 +17,6 @@
*/
#include "dtgtk/button.h"
#include "dtgtk/label.h"
#include "gui/gtk.h"
#include "common/darktable.h"
#include "common/image.h"
......
......@@ -17,7 +17,6 @@
*/
#include "dtgtk/button.h"
#include "dtgtk/label.h"
#include "gui/gtk.h"
#include "common/darktable.h"
#include "common/image.h"
......
......@@ -18,7 +18,6 @@
*/
#include "dtgtk/button.h"
#include "dtgtk/label.h"
#include "gui/gtk.h"
#include "common/darktable.h"
#include "common/image.h"
......
......@@ -25,7 +25,6 @@
#include "common/debug.h"
#include "common/opencl.h"
#include "bauhaus/bauhaus.h"
#include "dtgtk/label.h"
#include "dtgtk/resetlabel.h"
#include "dtgtk/togglebutton.h"
#include "dtgtk/button.h"
......
......@@ -25,7 +25,6 @@
#include "develop/imageop.h"
#include "control/control.h"
#include "common/debug.h"
#include "dtgtk/label.h"
#include "gui/accelerators.h"
#include "gui/gtk.h"
#include "gui/presets.h"
......@@ -89,7 +88,7 @@ typedef struct dt_iop_channelmixer_gui_data_t
{
GtkBox *vbox;
GtkWidget *combo1; // Output channel
GtkDarktableLabel *dtlabel1, *dtlabel2; // output channel, source channels
GtkLabel *dtlabel1, *dtlabel2; // output channel, source channels
GtkLabel *label1, *label2, *label3; // red, green, blue
GtkWidget *scale1, *scale2, *scale3; // red, green, blue
} dt_iop_channelmixer_gui_data_t;
......
......@@ -26,7 +26,6 @@ http://www.youtube.com/watch?v=JVoUgR6bhBc
#include "develop/imageop.h"
#include "bauhaus/bauhaus.h"
#include "gui/gtk.h"
#include "dtgtk/label.h"
#include "common/colorspaces.h"
#include "common/opencl.h"
......@@ -571,9 +570,7 @@ void gui_init(dt_iop_module_t *self)
#endif
/* lift */
gtk_box_pack_start(GTK_BOX(self->widget),
GTK_WIDGET(dtgtk_label_new(_("lift"), DARKTABLE_LABEL_TAB | DARKTABLE_LABEL_ALIGN_RIGHT)),
FALSE, FALSE, 5);
gtk_box_pack_start(GTK_BOX(self->widget), GTK_WIDGET(gtk_label_new(_("lift"))), FALSE, FALSE, 5);
g->lift_factor
= dt_bauhaus_slider_new_with_range(self, -1.0, 1.0, 0.005, p->lift[CHANNEL_FACTOR] - 1.0f, 3);
......@@ -612,10 +609,7 @@ void gui_init(dt_iop_module_t *self)
gtk_box_pack_start(GTK_BOX(self->widget), g->lift_b, TRUE, TRUE, 0);
/* gamma */
gtk_box_pack_start(
GTK_BOX(self->widget),
GTK_WIDGET(dtgtk_label_new(_("gamma"), DARKTABLE_LABEL_TAB | DARKTABLE_LABEL_ALIGN_RIGHT)), FALSE,
FALSE, 5);
gtk_box_pack_start(GTK_BOX(self->widget), GTK_WIDGET(gtk_label_new(_("gamma"))), FALSE, FALSE, 5);
g->gamma_factor
= dt_bauhaus_slider_new_with_range(self, -1.0, 1.0, 0.005, p->gamma[CHANNEL_FACTOR] - 1.0f, 3);
......@@ -654,9 +648,7 @@ void gui_init(dt_iop_module_t *self)
gtk_box_pack_start(GTK_BOX(self->widget), g->gamma_b, TRUE, TRUE, 0);
/* gain */
gtk_box_pack_start(GTK_BOX(self->widget),
GTK_WIDGET(dtgtk_label_new(_("gain"), DARKTABLE_LABEL_TAB | DARKTABLE_LABEL_ALIGN_RIGHT)),
FALSE, FALSE, 5);
gtk_box_pack_start(GTK_BOX(self->widget), GTK_WIDGET(gtk_label_new(_("gain"))), FALSE, FALSE, 5);
g->gain_factor
= dt_bauhaus_slider_new_with_range(self, -1.0, 1.0, 0.005, p->gain[CHANNEL_FACTOR] - 1.0f, 3);
......
......@@ -22,7 +22,6 @@
#include "bauhaus/bauhaus.h"
#include "common/darktable.h"
#include "develop/imageop.h"
#include "dtgtk/label.h"
#include "gui/gtk.h"
#include <gtk/gtk.h>
#include <stdlib.h>
......
......@@ -33,7 +33,6 @@
#include "common/debug.h"
#include "common/imageio.h"
#include "common/opencl.h"
#include "dtgtk/label.h"
#include "dtgtk/resetlabel.h"
#include "dtgtk/button.h"
#include "gui/accelerators.h"
......
......@@ -29,7 +29,6 @@
#include "develop/develop.h"
#include "develop/imageop.h"
#include "control/control.h"
#include "dtgtk/label.h"
#include "dtgtk/resetlabel.h"
#include "dtgtk/gradientslider.h"
#include "dtgtk/button.h"
......@@ -526,9 +525,7 @@ void cleanup(dt_iop_module_t *module)
static inline void gui_init_tab(struct dt_iop_module_t *self, const char *name, GtkDarktableButton **ppcolor,
GtkWidget **pphue, GtkWidget **ppsaturation)
{
gtk_box_pack_start(GTK_BOX(self->widget),
GTK_WIDGET(dtgtk_label_new(name, DARKTABLE_LABEL_TAB | DARKTABLE_LABEL_ALIGN_RIGHT)),
FALSE, FALSE, 5);
gtk_box_pack_start(GTK_BOX(self->widget), GTK_WIDGET(gtk_label_new(name)), FALSE, FALSE, 5);
// color button
GtkDarktableButton *color;
......
......@@ -23,7 +23,6 @@
#include "libs/lib.h"
#include "gui/accelerators.h"
#include "gui/gtk.h"
#include "dtgtk/label.h"
#include <gdk/gdkkeysyms.h>
#include "dtgtk/button.h"
......@@ -403,9 +402,7 @@ void gui_init(dt_lib_module_t *self)
GtkBox *hbox, *vbox1, *vbox2;
// Camera control
gtk_box_pack_start(GTK_BOX(self->widget),
dtgtk_label_new(_("camera control"), DARKTABLE_LABEL_TAB | DARKTABLE_LABEL_ALIGN_RIGHT),
TRUE, TRUE, 5);
gtk_box_pack_start(GTK_BOX(self->widget), gtk_label_new(_("camera control")), TRUE, TRUE, 5);
vbox1 = GTK_BOX(gtk_box_new(GTK_ORIENTATION_VERTICAL, 0));
vbox2 = GTK_BOX(gtk_box_new(GTK_ORIENTATION_VERTICAL, 0));
......@@ -484,9 +481,7 @@ void gui_init(dt_lib_module_t *self)
// Camera settings
dt_lib_camera_property_t *prop;
gtk_box_pack_start(GTK_BOX(self->widget),
dtgtk_label_new(_("properties"), DARKTABLE_LABEL_TAB | DARKTABLE_LABEL_ALIGN_RIGHT),
TRUE, TRUE, 0);
gtk_box_pack_start(GTK_BOX(self->widget), gtk_label_new(_("properties")), TRUE, TRUE, 0);
lib->gui.pvbox1 = GTK_BOX(gtk_box_new(GTK_ORIENTATION_VERTICAL, 0));
lib->gui.pvbox2 = GTK_BOX(gtk_box_new(GTK_ORIENTATION_VERTICAL, 0));
......@@ -648,10 +643,7 @@ void gui_init(dt_lib_module_t *self)
G_CALLBACK(_property_choice_callback), lib);
// user specified properties
gtk_box_pack_start(
GTK_BOX(self->widget),
dtgtk_label_new(_("additional properties"), DARKTABLE_LABEL_TAB | DARKTABLE_LABEL_ALIGN_RIGHT), TRUE,
TRUE, 5);
gtk_box_pack_start(GTK_BOX(self->widget), gtk_label_new(_("additional properties")), TRUE, TRUE, 5);
vbox1 = GTK_BOX(gtk_box_new(GTK_ORIENTATION_VERTICAL, 0));
vbox2 = GTK_BOX(gtk_box_new(GTK_ORIENTATION_VERTICAL, 0));
......
......@@ -21,7 +21,6 @@
#include "control/conf.h"
#include "develop/develop.h"
#include "develop/imageop.h"
#include "dtgtk/label.h"
#include "dtgtk/togglebutton.h"
#include "dtgtk/button.h"
#include "gui/accelerators.h"
......@@ -403,8 +402,7 @@ void gui_init(dt_lib_module_t *self)
GtkWidget *output_options = gtk_box_new(GTK_ORIENTATION_VERTICAL, 5);
GtkWidget *picker_subrow = gtk_box_new(GTK_ORIENTATION_HORIZONTAL, 2);
GtkWidget *restrict_button;
GtkWidget *samples_label
= dtgtk_label_new(_("live samples"), DARKTABLE_LABEL_TAB | DARKTABLE_LABEL_ALIGN_RIGHT);
GtkWidget *samples_label = gtk_label_new(_("live samples"));
GtkWidget *samples_options_row = gtk_box_new(GTK_ORIENTATION_HORIZONTAL, 2);
// Initializing self data structure
......
......@@ -27,7 +27,6 @@
#include "control/conf.h"
#include "control/signal.h"
#include "gui/gtk.h"
#include "dtgtk/label.h"
#include "libs/lib.h"
#include "gui/accelerators.h"
#include "gui/presets.h"
......@@ -451,7 +450,7 @@ void gui_init(dt_lib_module_t *self)
GtkWidget *label;
label = dtgtk_label_new(_("target storage"), DARKTABLE_LABEL_TAB | DARKTABLE_LABEL_ALIGN_RIGHT);
label = gtk_label_new(_("target storage"));
gtk_misc_set_alignment(GTK_MISC(label), 0.0, 0.5);
gtk_table_attach(GTK_TABLE(self->widget), label, 0, 2, 0, 1, GTK_FILL | GTK_EXPAND, 0, 0, 0);
d->storage = GTK_COMBO_BOX(gtk_combo_box_text_new());
......@@ -473,7 +472,7 @@ void gui_init(dt_lib_module_t *self)
gtk_table_attach(GTK_TABLE(self->widget), GTK_WIDGET(d->storage_box), 0, 2, 2, 3, GTK_EXPAND | GTK_FILL, 0,
0, 0);
label = dtgtk_label_new(_("file format"), DARKTABLE_LABEL_TAB | DARKTABLE_LABEL_ALIGN_RIGHT);
label = gtk_label_new(_("file format"));
gtk_misc_set_alignment(GTK_MISC(label), 0.0, 0.5);
gtk_table_set_row_spacing(GTK_TABLE(self->widget), 2, 20);
gtk_table_attach(GTK_TABLE(self->widget), label, 0, 2, 3, 4, GTK_EXPAND | GTK_FILL, 0, 0, 0);
......@@ -487,7 +486,7 @@ void gui_init(dt_lib_module_t *self)
gtk_table_attach(GTK_TABLE(self->widget), GTK_WIDGET(d->format_box), 0, 2, 5, 6, GTK_EXPAND | GTK_FILL, 0,
0, 0);
label = dtgtk_label_new(_("global options"), DARKTABLE_LABEL_TAB | DARKTABLE_LABEL_ALIGN_RIGHT);
label = gtk_label_new(_("global options"));
gtk_table_set_row_spacing(GTK_TABLE(self->widget), 5, 20);
gtk_table_attach(GTK_TABLE(self->widget), label, 0, 2, 6, 7, GTK_EXPAND | GTK_FILL, 0, 0, 0);
d->width = GTK_SPIN_BUTTON(gtk_spin_button_new_with_range(0, 10000, 1));
......
......@@ -31,7 +31,6 @@
#ifdef HAVE_GPHOTO2
#include "control/jobs/camera_jobs.h"
#endif
#include "dtgtk/label.h"
#include "dtgtk/button.h"
#include "gui/accelerators.h"
#include "gui/gtk.h"
......@@ -204,8 +203,7 @@ void _lib_import_ui_devices_update(dt_lib_module_t *self)
count++;
/* add camera label */
GtkWidget *label
= GTK_WIDGET(dtgtk_label_new(camera->model, DARKTABLE_LABEL_TAB | DARKTABLE_LABEL_ALIGN_LEFT));
GtkWidget *label = GTK_WIDGET(gtk_label_new(camera->model));
gtk_box_pack_start(GTK_BOX(d->devices), label, TRUE, TRUE, 0);
/* set camera summary if available */
......
......@@ -30,7 +30,6 @@
#include "gui/gtk.h"
#include "gui/draw.h"
#include "gui/guides.h"
#include "dtgtk/label.h"
#include <gdk/gdkkeysyms.h>
#include "dtgtk/button.h"
......
......@@ -26,7 +26,6 @@
#include "libs/lib.h"
#include "gui/gtk.h"
#include "dtgtk/icon.h"
#include "dtgtk/label.h"
#include "gui/draw.h"
DT_MODULE(1)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment