[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]
gEDA-cvs: CVS update: o_pin.nw
User: werner
Date: 06/05/16 16:21:36
Modified: . o_pin.nw
Log:
fixed whichend draw and connection check in o_pin_end()
Revision Changes Path
1.11 +6 -44 eda/geda/devel/gschem/noweb/o_pin.nw
(In the diff below, changes in quantity of whitespace are not shown.)
Index: o_pin.nw
===================================================================
RCS file: /home/cvspsrv/cvsroot/eda/geda/devel/gschem/noweb/o_pin.nw,v
retrieving revision 1.10
retrieving revision 1.11
diff -u -b -r1.10 -r1.11
--- o_pin.nw 25 Feb 2006 15:00:58 -0000 1.10
+++ o_pin.nw 16 May 2006 20:21:36 -0000 1.11
@@ -265,9 +265,8 @@
int x1, y1;
int x2, y2;
int color;
- int size;
GList *other_objects = NULL;
- OBJECT *o_current;
+ OBJECT *o_current, *o_current_pin;
if (w_current->inside_action == 0) {
o_redraw(w_current, w_current->page_current->object_head);
@@ -284,32 +283,6 @@
/* w_current->last_x = fix_x(w_current, x);
w_current->last_y = fix_y(w_current, y);*/
- size = SCREENabs(w_current, PIN_WIDTH);
- if (w_current->pin_style == THICK ) {
- gdk_gc_set_line_attributes(w_current->xor_gc, size,
- GDK_LINE_SOLID,
- GDK_CAP_NOT_LAST,
- GDK_JOIN_MITER);
- }
-
- gdk_gc_set_foreground(w_current->xor_gc,
- x_get_darkcolor(w_current->select_color) );
- gdk_draw_line(w_current->window, w_current->xor_gc,
- w_current->start_x, w_current->start_y,
- w_current->last_x, w_current->last_y);
-
- if (w_current->pin_style == THICK ) {
- gdk_gc_set_line_attributes(w_current->xor_gc, 0,
- GDK_LINE_SOLID,
- GDK_CAP_NOT_LAST,
- GDK_JOIN_MITER);
-
- gdk_gc_set_line_attributes(w_current->gc, size,
- GDK_LINE_SOLID,
- GDK_CAP_NOT_LAST,
- GDK_JOIN_MITER);
- }
-
/* don't allow zero length pins */
if ( (w_current->start_x == w_current->last_x) &&
(w_current->start_y == w_current->last_y) ) {
@@ -320,17 +293,6 @@
return;
}
- gdk_gc_set_foreground(w_current->gc, x_get_color(color));
- gdk_draw_line(w_current->window, w_current->gc, w_current->start_x, w_current->start_y, w_current->last_x, w_current->last_y);
- gdk_draw_line(w_current->backingstore, w_current->gc, w_current->start_x, w_current->start_y, w_current->last_x, w_current->last_y);
-
- if (w_current->pin_style == THICK ) {
- gdk_gc_set_line_attributes(w_current->gc, 0,
- GDK_LINE_SOLID,
- GDK_CAP_NOT_LAST,
- GDK_JOIN_MITER);
- }
-
SCREENtoWORLD(w_current, w_current->start_x,w_current->start_y, &x1, &y1);
SCREENtoWORLD(w_current, w_current->last_x, w_current->last_y, &x2, &y2);
x1 = snap_grid(w_current, x1);
@@ -345,7 +307,8 @@
x1, y1, x2, y2,
PIN_TYPE_NET, 0);
- o_current = w_current->page_current->object_tail;
+ o_current = o_current_pin = w_current->page_current->object_tail;
+
if (scm_hook_empty_p(add_pin_hook) == SCM_BOOL_F &&
o_current != NULL) {
scm_run_hook(add_pin_hook,
@@ -353,13 +316,12 @@
SCM_EOL));
}
- other_objects = s_conn_return_others(other_objects,
- w_current->page_current->
- object_tail);
+ other_objects = s_conn_return_others(other_objects, o_current_pin);
o_cue_undraw_list(w_current, other_objects);
o_cue_draw_list(w_current, other_objects);
g_list_free(other_objects);
- o_cue_draw_single(w_current, w_current->page_current->object_tail);
+ o_cue_draw_single(w_current, o_current_pin);
+ o_pin_draw(w_current, o_current_pin);
w_current->start_x = (-1);
w_current->start_y = (-1);