mirror of
git://projects.qi-hardware.com/cae-tools.git
synced 2025-04-21 12:27:27 +03:00
cameo/: new gnuplot tag #%id= with generator-assigned identifier
Excellon and Gerber store the file name there.
This commit is contained in:
@@ -43,11 +43,12 @@ static void free_points(struct point *points)
|
||||
void path_free(struct path *path)
|
||||
{
|
||||
free_points(path->first);
|
||||
free((void *) path->id);
|
||||
free(path);
|
||||
}
|
||||
|
||||
|
||||
struct path *path_new(double r_tool)
|
||||
struct path *path_new(double r_tool, const char *id)
|
||||
{
|
||||
struct path *path;
|
||||
|
||||
@@ -55,6 +56,7 @@ struct path *path_new(double r_tool)
|
||||
path->r_tool = r_tool;
|
||||
path->outside = 0;
|
||||
path->notch = 0;
|
||||
path->id = id ? stralloc(id) : NULL;
|
||||
path->first = path->last = NULL;
|
||||
path->next = NULL;
|
||||
return path;
|
||||
@@ -65,7 +67,7 @@ static struct path *path_from(const struct path *old)
|
||||
{
|
||||
struct path *new;
|
||||
|
||||
new = path_new(old->r_tool);
|
||||
new = path_new(old->r_tool, old->id);
|
||||
new->outside = old->outside;
|
||||
new->notch = old->notch;
|
||||
return new;
|
||||
|
||||
Reference in New Issue
Block a user