Index: trunk/scconfig/Rev.h =================================================================== --- trunk/scconfig/Rev.h (revision 8971) +++ trunk/scconfig/Rev.h (revision 8972) @@ -1 +1 @@ -static const int myrev = 8741; +static const int myrev = 8972; Index: trunk/scconfig/Rev.tab =================================================================== --- trunk/scconfig/Rev.tab (revision 8971) +++ trunk/scconfig/Rev.tab (revision 8972) @@ -1,3 +1,4 @@ +8972 configure new source file in lib for sheet utils 8741 configure enable the sim plugins by default 8712 configure new sources for sim gui and sim config 8169 configure lib_target: support plugin to get some attributes put in the tEDAx netlist Index: trunk/src/libcschem/Makefile.in =================================================================== --- trunk/src/libcschem/Makefile.in (revision 8971) +++ trunk/src/libcschem/Makefile.in (revision 8972) @@ -53,6 +53,7 @@ util_path.o util_parse.o util_project.o + util_sheet.o util_wirenet.o vtcoutline.o vtoid.o Index: trunk/src/libcschem/util_sheet.c =================================================================== --- trunk/src/libcschem/util_sheet.c (nonexistent) +++ trunk/src/libcschem/util_sheet.c (revision 8972) @@ -0,0 +1,38 @@ +/* + * COPYRIGHT + * + * cschem - modular/flexible schematics editor - libcschem (core library) + * Copyright (C) 2023 Tibor 'Igor2' Palinkas + * + * (Supported by NLnet NGI0 Entrust in 2023) + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2.1 of the License, or (at your option) any later version.* + * + * This library 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 + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA + * + * Contact: + * Project page: http://repo.hu/projects/sch-rnd + * contact lead developer: http://www.repo.hu/projects/sch-rnd/contact.html + * mailing list: http://www.repo.hu/projects/sch-rnd/contact.html + */ + +#include "config.h" + +#include + +#include "util_sheet.h" + +void csch_sheet_setup(csch_sheet_t *dst, csch_sheet_setup_cfg_t cfg, int (*chk_copy_pen)(void *udata, csch_sheet_t *dst), void *udata) +{ + +} Index: trunk/src/libcschem/util_sheet.h =================================================================== --- trunk/src/libcschem/util_sheet.h (nonexistent) +++ trunk/src/libcschem/util_sheet.h (revision 8972) @@ -0,0 +1,12 @@ +#include + +typedef enum csch_sheet_setup_cfg_e { /* bitfield */ + CSCH_SSC_PENS, + CSCH_SSC_UUID +} csch_sheet_setup_cfg_t; + +/* Copy defaults into dst (from the default sheet) as cfg dictates; if + CSCH_SSC_PENS is true chk_copy_pen is called on each pen and the pen + is copied only if it returns non-zero. If chk_copy_pen is NULL, it is + assumed to always return 1. */ +void csch_sheet_setup(csch_sheet_t *dst, csch_sheet_setup_cfg_t cfg, int (*chk_copy_pen)(void *udata, csch_sheet_t *dst), void *udata);