2 #include "item_conduct.h"
4 ViewConduct::ViewConduct(Glib::ustring _name, int orientacion):ViewItem(_name)
7 case 0: // Caño vertical
8 image.set(PACKAGE_DATA_DIR"/plaqui-client/pixmaps/canio_n.png");
10 case 1: // Caño horizontal
11 image.set(PACKAGE_DATA_DIR"/plaqui-client/pixmaps/canio_s.png");
18 ViewConduct::~ViewConduct()
22 bool ViewConduct::on_image_expose_event(GdkEventExpose *e)
24 Glib::RefPtr<Gdk::Colormap> colormap = image.get_colormap();
25 Gdk::Color blanco = Gdk::Color("white");
26 colormap->alloc_color(blanco);
27 colormap->alloc_color(color);
28 gc->set_foreground(color);
29 gc->set_background(color);
31 w = image.get_width();
32 h = image.get_height();
33 if (actual_flow == 0) return true;
36 image.get_window()->draw_rectangle(gc, 1, w/2-3, 0, 6, h);
39 image.get_window()->draw_rectangle(gc, 1, 0, h/2-3, w, 6);