Fwd: Extension request: Auto-generate rectangles based on input values
Dear dev community members, I am not sure whether this is the right way to ask for it. But I would like to make an extension (feature) request for a client of mine who uses your application. He is using Inkscape on a daily basis and doing a lot of repetitive actions in the program for which we thought an extension would be a good solution to reduce the time in his work. This is basically what he wants:
He wants to fill 3 values: Width x Height x Depth (maybe in a popup) Based on these 3 values, 7 rectangles need to be created based on some calculation on the values he entered.
I have added an example outcome of what he wants to be produced. All other values can be calculated based on the initial 3 values he enters.
Is there anyone from the dev team who can help us out and discuss about the further requirements?
Hope to hear from you. Keep up the good work!
Kind regards, Ibrahim Duz
https://www.avast.com/sig-email?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=webmail&utm_term=icon Virus-free. www.avast.com https://www.avast.com/sig-email?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=webmail&utm_term=link <#m_2206815133251637354_DAB4FAD8-2DD7-40BB-A1B8-4E2AA1F9FDF2>
Dear Ibrahim Duz,
Are you looking for a contractor to help you make your extension? I don't think it would be very expensive, given the requirements.
I'm a contractor, and I've worked on a lot of python extensions. Email me privately if this is what you need.
Best Regards, Martin Owens
On Fri, 2019-05-31 at 23:44 +0200, Ibrahim Duz wrote:
Dear dev community members, I am not sure whether this is the right way to ask for it. But I would like to make an extension (feature) request for a client of mine who uses your application. He is using Inkscape on a daily basis and doing a lot of repetitive actions in the program for which we thought an extension would be a good solution to reduce the time in his work. This is basically what he wants:
He wants to fill 3 values: Width x Height x Depth (maybe in a popup) Based on these 3 values, 7 rectangles need to be created based on some calculation on the values he entered.
I have added an example outcome of what he wants to be produced. All other values can be calculated based on the initial 3 values he enters.
Is there anyone from the dev team who can help us out and discuss about the further requirements?
Hope to hear from you. Keep up the good work!
Kind regards, Ibrahim Duz
Virus-free. www.avast.com _______________________________________________ Inkscape-devel mailing list Inkscape-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/inkscape-devel
Hello all, We get requests for this CAD-like functionality a LOT, in forums. (For some reason, it seems like a lot of users think of Inkscape as a CAD program.) I'd be curious what developers thoughts about this are. I mean adding this type of feature to all of Inkscape, not just rectangles.
All best, brynn
-----Original Message----- From: doctormo@...400... Sent: Friday, May 31, 2019 6:00 PM To: Ibrahim Duz ; inkscape-devel@lists.sourceforge.net Subject: Re: [Inkscape-devel] Fwd: Extension request: Auto-generate rectangles based on input values
Dear Ibrahim Duz,
Are you looking for a contractor to help you make your extension? I don't think it would be very expensive, given the requirements.
I'm a contractor, and I've worked on a lot of python extensions. Email me privately if this is what you need.
Best Regards, Martin Owens
On Fri, 2019-05-31 at 23:44 +0200, Ibrahim Duz wrote:
Dear dev community members, I am not sure whether this is the right way to ask for it. But I would like to make an extension (feature) request for a client of mine who uses your application. He is using Inkscape on a daily basis and doing a lot of repetitive actions in the program for which we thought an extension would be a good solution to reduce the time in his work. This is basically what he wants:
He wants to fill 3 values: Width x Height x Depth (maybe in a popup) Based on these 3 values, 7 rectangles need to be created based on some calculation on the values he entered.
I have added an example outcome of what he wants to be produced. All other values can be calculated based on the initial 3 values he enters.
Is there anyone from the dev team who can help us out and discuss about the further requirements?
Hope to hear from you. Keep up the good work!
Kind regards, Ibrahim Duz
Virus-free. www.avast.com _______________________________________________ Inkscape-devel mailing list Inkscape-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/inkscape-devel
_______________________________________________ Inkscape-devel mailing list Inkscape-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/inkscape-devel
As a side note: A similar problem was the original reason I started coding on Inkscape: The initial plan was to add a simple command line that allows to create objects or read an object list from a text file. (For me) it is just the most efficient way to create objects at exact locations and given dimensions, for example, for technical or scientific illustrations. However, I decided to pursue a more general approach and started integrating Python scripting (which I have put on hold until after 1.0 is out). I would then (if I still had demand) implement the "CAD-like" features as python scripts. The funny thing is, just the hard coded function for creating circles, lines and boxes would have been finished by now if I hadn't chosen the more flexible but complicated approach.
Regards, wiesi
brynn <brynn@...3133...> hat am 2. Juni 2019 um 12:50 geschrieben:
Hello all, We get requests for this CAD-like functionality a LOT, in forums. (For some reason, it seems like a lot of users think of Inkscape as a CAD program.) I'd be curious what developers thoughts about this are. I mean adding this type of feature to all of Inkscape, not just rectangles.
All best, brynn
-----Original Message----- From: doctormo@...400... Sent: Friday, May 31, 2019 6:00 PM To: Ibrahim Duz ; inkscape-devel@lists.sourceforge.net Subject: Re: [Inkscape-devel] Fwd: Extension request: Auto-generate rectangles based on input values
Dear Ibrahim Duz,
Are you looking for a contractor to help you make your extension? I don't think it would be very expensive, given the requirements.
I'm a contractor, and I've worked on a lot of python extensions. Email me privately if this is what you need.
Best Regards, Martin Owens
On Fri, 2019-05-31 at 23:44 +0200, Ibrahim Duz wrote:
Dear dev community members, I am not sure whether this is the right way to ask for it. But I would like to make an extension (feature) request for a client of mine who uses your application. He is using Inkscape on a daily basis and doing a lot of repetitive actions in the program for which we thought an extension would be a good solution to reduce the time in his work. This is basically what he wants:
He wants to fill 3 values: Width x Height x Depth (maybe in a popup) Based on these 3 values, 7 rectangles need to be created based on some calculation on the values he entered.
I have added an example outcome of what he wants to be produced. All other values can be calculated based on the initial 3 values he enters.
Is there anyone from the dev team who can help us out and discuss about the further requirements?
Hope to hear from you. Keep up the good work!
Kind regards, Ibrahim Duz
Virus-free. www.avast.com _______________________________________________ Inkscape-devel mailing list Inkscape-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/inkscape-devel
Inkscape-devel mailing list Inkscape-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/inkscape-devel
Inkscape-devel mailing list Inkscape-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/inkscape-devel
However, I decided to pursue a more general approach and started integrating Python scripting (which I have put on hold until after 1.0 is out). I would then (if I still had demand) implement the "CAD-like" features as python scripts. The funny thing is, just the hard coded function for creating circles, lines and boxes would have been finished by now if I hadn't chosen the more flexible but complicated approach.
You made the right choice. Your Python scripting modifications will make developing flexible extensions much easier. Thanks so much for working on this much anticipated and needed feature!
-C
brynn <brynn@...3133...> hat am 2. Juni 2019 um 12:50 geschrieben:
Hello all, We get requests for this CAD-like functionality a LOT, in
forums. (For
some reason, it seems like a lot of users think of Inkscape as a CAD
program.)
I'd be curious what developers thoughts about this are. I mean adding
this type
of feature to all of Inkscape, not just rectangles.
All best, brynn
-----Original Message----- From: doctormo@...400... Sent: Friday, May 31, 2019 6:00 PM To: Ibrahim Duz ; inkscape-devel@lists.sourceforge.net Subject: Re: [Inkscape-devel] Fwd: Extension request: Auto-generate
rectangles
based on input values
Dear Ibrahim Duz,
Are you looking for a contractor to help you make your extension? I don't think it would be very expensive, given the requirements.
I'm a contractor, and I've worked on a lot of python extensions. Email me privately if this is what you need.
Best Regards, Martin Owens
On Fri, 2019-05-31 at 23:44 +0200, Ibrahim Duz wrote:
Dear dev community members, I am not sure whether this is the right way to ask for it. But I would like to make an extension (feature) request for a client of mine who uses your application. He is using Inkscape on a daily basis and doing a lot of repetitive actions in the program for which we thought an extension would be a good solution to reduce the time in his work. This is basically what he wants:
He wants to fill 3 values: Width x Height x Depth (maybe in a popup) Based on these 3 values, 7 rectangles need to be created based on some calculation on the values he entered.
I have added an example outcome of what he wants to be produced. All other values can be calculated based on the initial 3 values he enters.
Is there anyone from the dev team who can help us out and discuss about the further requirements?
Hope to hear from you. Keep up the good work!
Kind regards, Ibrahim Duz
Virus-free. www.avast.com _______________________________________________ Inkscape-devel mailing list Inkscape-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/inkscape-devel
Inkscape-devel mailing list Inkscape-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/inkscape-devel
Inkscape-devel mailing list Inkscape-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/inkscape-devel
Inkscape-devel mailing list Inkscape-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/inkscape-devel
I have used inkscape for CAD on occasion. It generally has the features needed for light CAD work, but I usually move to another tool for more serious work. For example there are some things that are tricky to precisely position without resorting to the XML editor.
Although this particular feature is not something I'd use, I'd be in favour of more CAD like features.
I know lots of people who use inkscape to create designs for laser cutting.
Dan.
On Sun, 2 Jun 2019, 11:51 brynn, <brynn@...3133...> wrote:
Hello all, We get requests for this CAD-like functionality a LOT, in forums. (For some reason, it seems like a lot of users think of Inkscape as a CAD program.) I'd be curious what developers thoughts about this are. I mean adding this type of feature to all of Inkscape, not just rectangles.
All best, brynn
-----Original Message----- From: doctormo@...400... Sent: Friday, May 31, 2019 6:00 PM To: Ibrahim Duz ; inkscape-devel@lists.sourceforge.net Subject: Re: [Inkscape-devel] Fwd: Extension request: Auto-generate rectangles based on input values
Dear Ibrahim Duz,
Are you looking for a contractor to help you make your extension? I don't think it would be very expensive, given the requirements.
I'm a contractor, and I've worked on a lot of python extensions. Email me privately if this is what you need.
Best Regards, Martin Owens
On Fri, 2019-05-31 at 23:44 +0200, Ibrahim Duz wrote:
Dear dev community members, I am not sure whether this is the right way to ask for it. But I would like to make an extension (feature) request for a client of mine who uses your application. He is using Inkscape on a daily basis and doing a lot of repetitive actions in the program for which we thought an extension would be a good solution to reduce the time in his work. This is basically what he wants:
He wants to fill 3 values: Width x Height x Depth (maybe in a popup) Based on these 3 values, 7 rectangles need to be created based on some calculation on the values he entered.
I have added an example outcome of what he wants to be produced. All other values can be calculated based on the initial 3 values he enters.
Is there anyone from the dev team who can help us out and discuss about the further requirements?
Hope to hear from you. Keep up the good work!
Kind regards, Ibrahim Duz
Virus-free. www.avast.com _______________________________________________ Inkscape-devel mailing list Inkscape-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/inkscape-devel
Inkscape-devel mailing list Inkscape-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/inkscape-devel
Inkscape-devel mailing list Inkscape-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/inkscape-devel
On Jun 2, 2019, at 3:50 AM, brynn <brynn@...3133...> wrote:
Hello all, We get requests for this CAD-like functionality a LOT, in forums. (For some reason, it seems like a lot of users think of Inkscape as a CAD program.) I'd be curious what developers thoughts about this are. I mean adding this type of feature to all of Inkscape, not just rectangles.
I want to use this opportunity to address an "elephant in the room" type issue, which I personally see as more important than most of the commonly-requested CAD features.
In CAD programs, one sets and reads the width of the object by centerline only. If you set an object to 50 mm wide, it will unambiguously be 50 mm wide. This is, in a sense, the core feature of a CAD program.
However, when using Inkscape for CAD, it is crucially important to know that the width of an object includes the stroke width. That is to say, if you draw an object with a width of 50 mm and stroke of 1 mm, and subsequently change the stroke width, it will no longer be 50 mm wide. This is not obvious or intuitive to new users or users coming from CAD environments.
The difference between these two models for how parts are measured and drawn has profound consequences throughout the use of Inkscape for CAD. It reflects whether or not you can accurately enter or read the width of a part. It reflects how parts end up positioned when you use the align and distribute tools. It reflects how transformations work, and so on.
No matter how many special little CAD-like features are added, I suspect that this difference will continue to be a major stumbling block for the use of Inkscape in CAD-like applications.
A possible solution, potentially more impactful than most of the CAD-like features that are normally discussed (e.g., those at http://wiki.inkscape.org/wiki/index.php/CAD ) would be to have a real "CAD mode" for Inkscape, which would (1) enable Outline display mode and (2) treat all objects, in all respects expect saving/exporting, as though they had "stroke:none".
Some potential GUI methods to add this would be: * To add it as a new Display mode, View > Display Mode > CAD (though it affects behavior, not just viewing). * To add it as a new option type, Edit > Interface Mode > CAD (though it affects behavior, not just viewing). * To add it as an option in the Document preferences. * To add it as option under Behavior in the global preferences.
Having a feature like this would make all of those proposed special-purpose extensions that much more useful.
[Aside 1: You can somewhat emulate CAD-like behavior in Inkscape by turning off strokes completely, and using only fills. I've done mechanical design this way, but it is cumbersome to ensure that strokes are uniformly and consistently disabled when working with multiple files and designs.]
[Aside 2: I am not advocating turning Inkscape into a full CAD tool. However, it would be great to make the tools that we have work better for more applications.]
Windell H. Oskay, Ph.D. Co-Founder and Chief Scientist Evil Mad Scientist Laboratories 1285 Forgewood Ave Sunnyvale CA 94089 http://www.evilmadscientist.com/
Hi Windell,
Thanks for your comments.
I should note that I'm not a programmer, and can't really address that part of your comments.
But doesn't the choice of bounding box settle the stroke width issue? With the Visual BB, measurements include the stroke width. With Geometric, it doesn't.
I would assume that most people who use Inkscape for any kind of cutting, must be using the Geometric BB....well, if they use strokes. Maybe some don't use strokes.
All best, brynn
-----Original Message----- From: Windell H. Oskay Sent: Sunday, June 02, 2019 4:55 PM To: inkscape-devel Subject: Re: [Inkscape-devel] Extension request: Auto-generate rectangles based on input values
On Jun 2, 2019, at 3:50 AM, brynn <brynn@...3133...> wrote:
Hello all, We get requests for this CAD-like functionality a LOT, in forums. (For some reason, it seems like a lot of users think of Inkscape as a CAD program.) I'd be curious what developers thoughts about this are. I mean adding this type of feature to all of Inkscape, not just rectangles.
I want to use this opportunity to address an "elephant in the room" type issue, which I personally see as more important than most of the commonly-requested CAD features.
In CAD programs, one sets and reads the width of the object by centerline only. If you set an object to 50 mm wide, it will unambiguously be 50 mm wide. This is, in a sense, the core feature of a CAD program.
However, when using Inkscape for CAD, it is crucially important to know that the width of an object includes the stroke width. That is to say, if you draw an object with a width of 50 mm and stroke of 1 mm, and subsequently change the stroke width, it will no longer be 50 mm wide. This is not obvious or intuitive to new users or users coming from CAD environments.
The difference between these two models for how parts are measured and drawn has profound consequences throughout the use of Inkscape for CAD. It reflects whether or not you can accurately enter or read the width of a part. It reflects how parts end up positioned when you use the align and distribute tools. It reflects how transformations work, and so on.
No matter how many special little CAD-like features are added, I suspect that this difference will continue to be a major stumbling block for the use of Inkscape in CAD-like applications.
A possible solution, potentially more impactful than most of the CAD-like features that are normally discussed (e.g., those at http://wiki.inkscape.org/wiki/index.php/CAD ) would be to have a real "CAD mode" for Inkscape, which would (1) enable Outline display mode and (2) treat all objects, in all respects expect saving/exporting, as though they had "stroke:none".
Some potential GUI methods to add this would be: * To add it as a new Display mode, View > Display Mode > CAD (though it affects behavior, not just viewing). * To add it as a new option type, Edit > Interface Mode > CAD (though it affects behavior, not just viewing). * To add it as an option in the Document preferences. * To add it as option under Behavior in the global preferences.
Having a feature like this would make all of those proposed special-purpose extensions that much more useful.
[Aside 1: You can somewhat emulate CAD-like behavior in Inkscape by turning off strokes completely, and using only fills. I've done mechanical design this way, but it is cumbersome to ensure that strokes are uniformly and consistently disabled when working with multiple files and designs.]
[Aside 2: I am not advocating turning Inkscape into a full CAD tool. However, it would be great to make the tools that we have work better for more applications.]
Windell H. Oskay, Ph.D. Co-Founder and Chief Scientist Evil Mad Scientist Laboratories 1285 Forgewood Ave Sunnyvale CA 94089 http://www.evilmadscientist.com/
_______________________________________________ Inkscape-devel mailing list Inkscape-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/inkscape-devel
On Jun 2, 2019, at 5:28 PM, brynn <brynn@...3133...> wrote:
But doesn't the choice of bounding box settle the stroke width issue? With the Visual BB, measurements include the stroke width. With Geometric, it doesn't.
I would assume that most people who use Inkscape for any kind of cutting, must be using the Geometric BB....well, if they use strokes. Maybe some don't use strokes.
Well, actually -- ha! -- that totally solves it. I never knew about that option, after designing hardware in Inkscape for ~ten years.
How about we add a guide for using Inkscape for CAD, which includes advice to use the Geometric BB (and why to use it) and to turn on Outline Display Mode? Those two non-obvious options together put Inkscape on pretty good footing for doing CAD.
Thanks!
Windell H. Oskay, Ph.D. Co-Founder and Chief Scientist Evil Mad Scientist Laboratories 1285 Forgewood Ave Sunnyvale CA 94089 http://www.evilmadscientist.com/
Well....because of my experience, having to so often explain to people (in forums) that Inkscape is not a CAD program, I would hesitate to call it a "guide for CAD". But I wouldn't be opposed to some kind of guide, and calling it anything but "CAD".
It has been discussed among developers (at least I've seen a couple on the mailing list) about some day having different "flavors" of Inkscape. So for example, a beginners version, a version for people who use it for different types of cutting, a version for artists, etc. So that certainly would be something they would include for the "cutters version".
Are you interested in writing a tutorial? What other info, besides those 2 things, would you include in the guide? I guess there must be certain features which most "cutters" like to use?
We've just been discussing possibly setting up some kind of system to create a series of "official" tutorials. So my brain is slightly in 'tutorial mode' at the moment.
But I also enjoy writing tutorials. So if you don't want to write one, I'd be glad to do it. I'm just not closely familiar with those common tools. Once I know what they are, I could write about them (probably). I'm just not sure what all they might be.
Oh! For sure the Scale setting (new in 0.91) and how to change Display Units without messing up the scale. That should be included, I would think.
What else?
By the way, do you use the Gcodetools extensions? The community generally needs a good tutorial for using those! The ones I've seen focus mostly on what to do after you're finished with Inkscape, and for all the different brands of hardware. But we need one for just those Inkscape extensions. And not using this kind of hardware myself, I need help.
All best, brynn
-----Original Message----- From: Windell H. Oskay Sent: Sunday, June 02, 2019 6:37 PM To: inkscape-devel Subject: Re: [Inkscape-devel] Extension request: Auto-generate rectangles based on input values
On Jun 2, 2019, at 5:28 PM, brynn <brynn@...3133...> wrote:
But doesn't the choice of bounding box settle the stroke width issue? With the Visual BB, measurements include the stroke width. With Geometric, it doesn't.
I would assume that most people who use Inkscape for any kind of cutting, must be using the Geometric BB....well, if they use strokes. Maybe some don't use strokes.
Well, actually -- ha! -- that totally solves it. I never knew about that option, after designing hardware in Inkscape for ~ten years.
How about we add a guide for using Inkscape for CAD, which includes advice to use the Geometric BB (and why to use it) and to turn on Outline Display Mode? Those two non-obvious options together put Inkscape on pretty good footing for doing CAD.
Thanks!
Windell H. Oskay, Ph.D. Co-Founder and Chief Scientist Evil Mad Scientist Laboratories 1285 Forgewood Ave Sunnyvale CA 94089 http://www.evilmadscientist.com/
_______________________________________________ Inkscape-devel mailing list Inkscape-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/inkscape-devel
On Tue, 2019-06-04 at 08:28 -0600, brynn wrote:
Inkscape is not a CAD program
Computer Aided Design - Inkscape must be a CAD program. Not a great CAD program, but it is one. We have a whole clade of users who are using Inkscape as a CAD program so it's important that we at least consider ourselves to be a bad CAD program at least.
Best Regards, Martin Owens
Well, under the general definition "computer aided design" Inkscape qualifies. But it's not anything like typical CAD programs. And it doesn't have the same goal or intent of typical CAD programs.
Do you really see Inkscape as in that same category?
If "Inkscape is not a CAD program" is not an appropriate answer, I would welcome suggestions how to answer messages like this:
"Inkscape is a terrible CAD program. Where do I enter the length and angle of the line? How can I draw a line if I can't enter the length and angle?"
(substitute radius/diameter/circumference, etc, for a circle; or dimensions for rectangle)
All best, brynn
-----Original Message----- From: doctormo@...400... Sent: Tuesday, June 04, 2019 1:46 PM To: brynn ; Windell H. Oskay ; inkscape-devel Subject: Re: [Inkscape-devel] Extension request: Auto-generate rectangles based on input values
On Tue, 2019-06-04 at 08:28 -0600, brynn wrote:
Inkscape is not a CAD program
Computer Aided Design - Inkscape must be a CAD program. Not a great CAD program, but it is one. We have a whole clade of users who are using Inkscape as a CAD program so it's important that we at least consider ourselves to be a bad CAD program at least.
Best Regards, Martin Owens
On 04-Jun-2019 18:11, brynn wrote:
If "Inkscape is not a CAD program" is not an appropriate answer, I would welcome suggestions how to answer messages like this:
"Inkscape is a terrible CAD program. Where do I enter the length and angle of the line? How can I draw a line if I can't enter the length and angle?"
(substitute radius/diameter/circumference, etc, for a circle; or dimensions for rectangle)
Well, this probably isn't what the target audience would want to hear, but since it sounds like the questioner might have a set of simple elements with known sizes, locations, and orientations derived from who knows what (actual measurements, some abstract calculation?), it isn't unreasonable to ask if there might be a way to provide a quick and easy conversion of that data to a drawing through Inkscape.
For instance, if the user could write their data as a text file made of simple declarative 1 line statements like:
moveto,x,y lineto,x,y ray,x,y,length,angle ray2,x1,y1,x2,y2 square,x,y,side,angle #x,y is center square2,x,y,side,angle #x,y is lower left corner rectangle,x,y,width,height,angle #x,y is center rectangle2,x,y,width,height,angle #x,y is lower left corner circle,x,y,radius ellipse,x,y,radiusA,radiusB,angle ellipse2,x,y,radius,eval,angle text,x,y,points,font,angle,text_string draw_color,color_name draw_color_rgb,R,G,B fill_color,color_name fill_color_rgb,R,G,B draw_width,width (etc.) quit
it would not be hard to write a converter to read that and write it out again as SVG, either to a file or imported directly into Inkscape.
Yes, this duplicates features of many other graphics languages, from cgm to hpgl to postscript. So it might be best to pick the text form of one of those standards and write an importer for it. (Not postscript though, that is Reverse Polish, too bizarre for the average user.) For all I know there may already be an import option which works like this. If so, point said user to it and say "have at it".
Regards,
David Mathog mathog@...1176... Manager, Sequence Analysis Facility, Biology Division, Caltech
The question is also, if we would want this for interactive entry, batch processing or processing the output of other tools: It is usually rather easy (but nevertheless some work) to create an external tool to convert such a list to SVG. For my own tools that generate graphics files I usually end up outputting SVG files (or parts of them) directly, because outputting, for example,
<line x1="45.6" y1="23" x2="-15" y2="8" />
is not much more complicated than
moveto 45.6, 23 lineto -15, 8
Regards wiesi
David Mathog <mathog@...1176...> hat am 5. Juni 2019 um 03:49 geschrieben:
On 04-Jun-2019 18:11, brynn wrote:
If "Inkscape is not a CAD program" is not an appropriate answer, I would welcome suggestions how to answer messages like this:
"Inkscape is a terrible CAD program. Where do I enter the length and angle of the line? How can I draw a line if I can't enter the length and angle?"
(substitute radius/diameter/circumference, etc, for a circle; or dimensions for rectangle)
Well, this probably isn't what the target audience would want to hear, but since it sounds like the questioner might have a set of simple elements with known sizes, locations, and orientations derived from who knows what (actual measurements, some abstract calculation?), it isn't unreasonable to ask if there might be a way to provide a quick and easy conversion of that data to a drawing through Inkscape.
For instance, if the user could write their data as a text file made of simple declarative 1 line statements like:
moveto,x,y lineto,x,y ray,x,y,length,angle ray2,x1,y1,x2,y2 square,x,y,side,angle #x,y is center square2,x,y,side,angle #x,y is lower left corner rectangle,x,y,width,height,angle #x,y is center rectangle2,x,y,width,height,angle #x,y is lower left corner circle,x,y,radius ellipse,x,y,radiusA,radiusB,angle ellipse2,x,y,radius,eval,angle text,x,y,points,font,angle,text_string draw_color,color_name draw_color_rgb,R,G,B fill_color,color_name fill_color_rgb,R,G,B draw_width,width (etc.) quit
it would not be hard to write a converter to read that and write it out again as SVG, either to a file or imported directly into Inkscape.
Yes, this duplicates features of many other graphics languages, from cgm to hpgl to postscript. So it might be best to pick the text form of one of those standards and write an importer for it. (Not postscript though, that is Reverse Polish, too bizarre for the average user.) For all I know there may already be an import option which works like this. If so, point said user to it and say "have at it".
Regards,
David Mathog mathog@...1176... Manager, Sequence Analysis Facility, Biology Division, Caltech
Inkscape-devel mailing list Inkscape-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/inkscape-devel
On 04-Jun-2019 23:21, wiesi--- via Inkscape-devel wrote:
The question is also, if we would want this for interactive entry,
Probably not. I cannot think of a use case for preexisting data where it would not be better to format it first rather than type it in. Especially because the data might already be in some form of text file which could be rapidly converted to input format with various sorts of batch edit commands (ie, select range, substitute in a certain way)
batch processing or processing the output of other tools
These are the same aren't they? Unless by the latter you mean have it hook such output directly from Inkscape without saving the intermediary file.
: It is usually rather easy (but nevertheless some work) to create an external tool to convert such a list to SVG. For my own tools that generate graphics files I usually end up outputting SVG files (or parts of them) directly, because outputting, for example,
<line x1="45.6" y1="23" x2="-15" y2="8" />
Because SVG is SGML like specifying rotation angles and formatting gets complicated in a hurry.
is not much more complicated than
moveto 45.6, 23 lineto -15, 8
A variant of that uses "angle" operators. Those effectively shift the rotation in the current transformation matrix but are easy for people to understand because it is just like using a protractor and a ruler (the ancient Greeks would get it) and they don't have to do the math to get pairs of coordinates from a set of measured lengths, the input program does it. I don't recall where I saw that idea but it isn't mine. This method simplifies the conversion of many sorts of measurements to graphics coordinates because moveto/lineto/etc. take fewer parameters. This:
origin # equivalent to moveto 0,0 degree_angle 45 moveto1 100 #in this context, same as moveto 70.7 70.7 # draw an object, typically much more complicated than this one deg_angle 0 # absolute angle set in degrees #start # optional mark for later "close" line1 5 # start x,y, angle, length define 2nd point's coordinates inc_deg_angle 90 #0 + 90 = 90 line1 5 inc_deg_angle 90 #90 + 90 = 180 line1 5 inc_deg_angle 90 #180 + 90 = 270 line1 5 #line_close #use instead of preceding if start was used square_ll 10 #use current angle, starts at lower left corner
draws a square of side 5 counter clockwise (assuming origin 0,0 is at lower left corner, other standards are possible) and then a square of side 10 below it.
The place where all of this goes wrong, in terms of CAD, is when the input data (measurements or calculations) are slightly off and the path isn't trivial like a square. Surely we have all been there, measure around a building with a complex outer path and that path doesn't quite close because of accumulated errors. (In the example above maybe the lengths were 5.01, 5.02, 4.99, 5.00). That is where start/close can be helpful, it allows a "fix this" function to be called automatically. There are many such functions (assume angles are correct, assume lengths are correct, assume both may have errors, etc. etc. etc.). It should also throw an error on a really extreme error, as these are common when writing down data, like "5" when it should be ".5".
Rather than reinventing the wheel I still think adopting some existing standard for this sort of input is the simplest way to go. It can be extended with "fix this" functions if it supports some variant of start/close.
Regards,
David Mathog mathog@...1176... Manager, Sequence Analysis Facility, Biology Division, Caltech
Regards wiesi
David Mathog <mathog@...1176...> hat am 5. Juni 2019 um 03:49 geschrieben:
On 04-Jun-2019 18:11, brynn wrote:
If "Inkscape is not a CAD program" is not an appropriate answer, I would welcome suggestions how to answer messages like this:
"Inkscape is a terrible CAD program. Where do I enter the length and angle of the line? How can I draw a line if I can't enter the length and angle?"
(substitute radius/diameter/circumference, etc, for a circle; or dimensions for rectangle)
Well, this probably isn't what the target audience would want to hear, but since it sounds like the questioner might have a set of simple elements with known sizes, locations, and orientations derived from who knows what (actual measurements, some abstract calculation?), it isn't unreasonable to ask if there might be a way to provide a quick and easy conversion of that data to a drawing through Inkscape.
For instance, if the user could write their data as a text file made of simple declarative 1 line statements like:
moveto,x,y lineto,x,y ray,x,y,length,angle ray2,x1,y1,x2,y2 square,x,y,side,angle #x,y is center square2,x,y,side,angle #x,y is lower left corner rectangle,x,y,width,height,angle #x,y is center rectangle2,x,y,width,height,angle #x,y is lower left corner circle,x,y,radius ellipse,x,y,radiusA,radiusB,angle ellipse2,x,y,radius,eval,angle text,x,y,points,font,angle,text_string draw_color,color_name draw_color_rgb,R,G,B fill_color,color_name fill_color_rgb,R,G,B draw_width,width (etc.) quit
it would not be hard to write a converter to read that and write it out again as SVG, either to a file or imported directly into Inkscape.
Yes, this duplicates features of many other graphics languages, from cgm to hpgl to postscript. So it might be best to pick the text form of one of those standards and write an importer for it. (Not postscript though, that is Reverse Polish, too bizarre for the average user.) For all I know there may already be an import option which works like this. If so, point said user to it and say "have at it".
Regards,
David Mathog mathog@...1176... Manager, Sequence Analysis Facility, Biology Division, Caltech
Inkscape-devel mailing list Inkscape-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/inkscape-devel
Inkscape-devel mailing list Inkscape-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/inkscape-devel
Hhooy, I couldn't give that for an answer, because I don't understand it. But maybe it would be a solution for the original request?
brynn
-----Original Message----- From: David Mathog Sent: Tuesday, June 04, 2019 7:49 PM To: inkscape-devel@lists.sourceforge.net Subject: Re: [Inkscape-devel] Extension request: Auto-generate rectangles based on input values
On 04-Jun-2019 18:11, brynn wrote:
If "Inkscape is not a CAD program" is not an appropriate answer, I would welcome suggestions how to answer messages like this:
"Inkscape is a terrible CAD program. Where do I enter the length and angle of the line? How can I draw a line if I can't enter the length and angle?"
(substitute radius/diameter/circumference, etc, for a circle; or dimensions for rectangle)
Well, this probably isn't what the target audience would want to hear, but since it sounds like the questioner might have a set of simple elements with known sizes, locations, and orientations derived from who knows what (actual measurements, some abstract calculation?), it isn't unreasonable to ask if there might be a way to provide a quick and easy conversion of that data to a drawing through Inkscape.
For instance, if the user could write their data as a text file made of simple declarative 1 line statements like:
moveto,x,y lineto,x,y ray,x,y,length,angle ray2,x1,y1,x2,y2 square,x,y,side,angle #x,y is center square2,x,y,side,angle #x,y is lower left corner rectangle,x,y,width,height,angle #x,y is center rectangle2,x,y,width,height,angle #x,y is lower left corner circle,x,y,radius ellipse,x,y,radiusA,radiusB,angle ellipse2,x,y,radius,eval,angle text,x,y,points,font,angle,text_string draw_color,color_name draw_color_rgb,R,G,B fill_color,color_name fill_color_rgb,R,G,B draw_width,width (etc.) quit
it would not be hard to write a converter to read that and write it out again as SVG, either to a file or imported directly into Inkscape.
Yes, this duplicates features of many other graphics languages, from cgm to hpgl to postscript. So it might be best to pick the text form of one of those standards and write an importer for it. (Not postscript though, that is Reverse Polish, too bizarre for the average user.) For all I know there may already be an import option which works like this. If so, point said user to it and say "have at it".
Regards,
David Mathog mathog@...1176... Manager, Sequence Analysis Facility, Biology Division, Caltech
_______________________________________________ Inkscape-devel mailing list Inkscape-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/inkscape-devel
On Tue, 2019-06-04 at 19:11 -0600, brynn wrote:
Well, under the general definition "computer aided design" Inkscape qualifies. But it's not anything like typical CAD programs. And it doesn't have the same goal or intent of typical CAD programs.
Goal is a bit of a cloudy one for an open source project. We have competing goals already. Are we a program for making Ponies or a program for making maps? Maybe one for signing PDF documents?
I've used Inkscape to make physical objects (stickers, pamphlets, cogs, cards), I've also used it to make user interface mockups, website mockups and plenty else which is all CAD.
Inkscape's CAD features for certain kinds of CAD are a bit rusty and not well focused. But that doesn't change how people use the software, or that it's well regarded by certain classes of CAD users.
Best Regards, Martin Owens
One option to improve the CAD functionality would be to try to use the geometry core of some existing open source CAD project, like LibreCAD. Even if it is possible, it would still be a lot of work, I think.
Reagards Thomas
doctormo@...400... hat am 5. Juni 2019 um 05:02 geschrieben:
On Tue, 2019-06-04 at 19:11 -0600, brynn wrote:
Well, under the general definition "computer aided design" Inkscape qualifies. But it's not anything like typical CAD programs. And it doesn't have the same goal or intent of typical CAD programs.
Goal is a bit of a cloudy one for an open source project. We have competing goals already. Are we a program for making Ponies or a program for making maps? Maybe one for signing PDF documents?
I've used Inkscape to make physical objects (stickers, pamphlets, cogs, cards), I've also used it to make user interface mockups, website mockups and plenty else which is all CAD.
Inkscape's CAD features for certain kinds of CAD are a bit rusty and not well focused. But that doesn't change how people use the software, or that it's well regarded by certain classes of CAD users.
Best Regards, Martin Owens
Inkscape-devel mailing list Inkscape-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/inkscape-devel
participants (7)
-
unknown@example.com
-
brynn
-
C R
-
Daniel Bailey
-
David Mathog
-
Ibrahim Duz
-
Windell H. Oskay