[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]
gEDA-cvs: CVS update: x_autonumber.c
User: werner
Date: 06/11/09 13:50:00
Modified: . Tag: autonumber x_autonumber.c
Log:
* src/x_autonumber.c: (scope_skip == SCOPE_SELECTED) didn't work as
expected, fixed it.
Revision Changes Path
No revision
No revision
1.1.2.3 +5 -4 eda/geda/gaf/gschem/src/Attic/x_autonumber.c
(In the diff below, changes in quantity of whitespace are not shown.)
Index: x_autonumber.c
===================================================================
RCS file: /home/cvspsrv/cvsroot/eda/geda/gaf/gschem/src/Attic/x_autonumber.c,v
retrieving revision 1.1.2.2
retrieving revision 1.1.2.3
diff -u -b -r1.1.2.2 -r1.1.2.3
--- x_autonumber.c 7 Nov 2006 20:30:29 -0000 1.1.2.2
+++ x_autonumber.c 9 Nov 2006 18:50:00 -0000 1.1.2.3
@@ -307,7 +307,6 @@
{
gint i, len, isnumbered=1;
-
len = strlen(autotext->current_searchtext);
/* first find out whether we can ignore that object */
if (o_current->type != OBJ_TEXT /* text object */
@@ -336,7 +335,9 @@
&& (!isnumbered || (autotext->scope_overwrite)))
return AUTONUMBER_RENUMBER;
- if (isnumbered) {
+ if (isnumbered
+ && !(autotext->scope_skip == SCOPE_SELECTED
+ && !(o_current->selected) && autotext->root_page)) {
sscanf(&(o_current->text->string[len])," %d", number);
return AUTONUMBER_RESPECT; /* numbered objects which we don't renumber */
}
@@ -705,8 +706,8 @@
for (page_item = pages; page_item != NULL; page_item = g_list_next(page_item)) {
s_page_goto(w_current, page_item->data);
autotext->root_page = (pages->data == page_item->data);
- /* build a page database if we're numbering pagebypage */
- if (autotext->scope_skip == SCOPE_PAGE) {
+ /* build a page database if we're numbering pagebypage or selection only*/
+ if (autotext->scope_skip == SCOPE_PAGE || autotext->scope_skip == SCOPE_SELECTED) {
autonumber_get_used(w_current, autotext);
}
_______________________________________________
geda-cvs mailing list
geda-cvs@xxxxxxxxxxxxxx
http://www.seul.org/cgi-bin/mailman/listinfo/geda-cvs