When I use echo to print output (useful for printing part lists in parametric
designs) to the output window, it prints not only the argument, it prints
the entire line.
Example:
echo("Hello world!");
results in:
echo("Hello world!");
I would expect it to print:
Hello World!
Sure, it's readable, and it's trivial to make a program to trim the output
if needed, but is there any upside to this behaviour which motivates it's
existence? It just feels "un-neat".
--
Sent from: http://forum.openscad.org/
It should result in:
ECHO: "Hello world!"
I presume the prefix is to distinguish it from other messages. If you are
getting the whole source line printed then it is a bug.
On 14 September 2017 at 08:20, Troberg troberg.anders@gmail.com wrote:
When I use echo to print output (useful for printing part lists in
parametric
designs) to the output window, it prints not only the argument, it prints
the entire line.
Example:
echo("Hello world!");
results in:
echo("Hello world!");
I would expect it to print:
Hello World!
Sure, it's readable, and it's trivial to make a program to trim the output
if needed, but is there any upside to this behaviour which motivates it's
existence? It just feels "un-neat".
--
Sent from: http://forum.openscad.org/
OpenSCAD mailing list
Discuss@lists.openscad.org
http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org
True, I was in a bit of hurry and didn't check the details.
Still, I think, at least for my use, that the downsides by far outweigh the
upsides, and it's pretty much the opposite of how other dev environments do
it (at least the ones I've used).
If you just want enhanced visibility, I'd consider using an alternative
color.
--
Sent from: http://forum.openscad.org/
If it was just a different colour then I wouldn't be able to filter it with
a script.
I think it is far too late to change now as people like me have scripts
built around it for making BOMs for many years.
On 14 September 2017 at 11:08, Troberg troberg.anders@gmail.com wrote:
True, I was in a bit of hurry and didn't check the details.
Still, I think, at least for my use, that the downsides by far outweigh the
upsides, and it's pretty much the opposite of how other dev environments do
it (at least the ones I've used).
If you just want enhanced visibility, I'd consider using an alternative
color.
--
Sent from: http://forum.openscad.org/
OpenSCAD mailing list
Discuss@lists.openscad.org
http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org
On 2017-09-14 11:08, Troberg wrote:
Still, I think, at least for my use, that the downsides by far outweigh the
upsides, and it's pretty much the opposite of how other dev environments do
it (at least the ones I've used).
Perhaps this should be an enhancement request for echo() to take an
argument to make it less verbose? If this also allowed it to be made
more verbose to also include such luxuries as the file/line, then even
better!
That would be a nice solution.
Or, possibly, to be able to divert it to a separate window (and, even
better, optionally a file), so it won't get intermingled with other output.
--
Sent from: http://forum.openscad.org/
nophead wrote
I think it is far too late to change now as people like me have scripts
built around it for making BOMs for many years.
I can see that problem, it's not fun going back and rebuild old scripts...
--
Sent from: http://forum.openscad.org/
On 9/14/2017 4:28 AM, Troberg wrote:
nophead wrote
I think it is far too late to change now as people like me have scripts
built around it for making BOMs for many years.
I can see that problem, it's not fun going back and rebuild old scripts...
Not that it wouldn't be a nuisance, but the straightforward thing to do
would be to change the .scad files to emit the "ECHO:" so that the
post-processing scripts wouldn't need to change.
On 2017-09-14 15:59, Jordan Brown wrote:
Not that it wouldn't be a nuisance, but the straightforward thing to
do would be to change the .scad files to emit the "ECHO:" so that the
post-processing scripts wouldn't need to change.
Maybe ...
$echo_verbose = "quiet";
echo ("This won't print the ECHO: prefix.");
echo ("This will", $echo_verbose="normal");
echo ("This will also give file and line number", $echo_verbose="high");
or something.
As long as default matches current behaviour, I can't see anyone
objecting and it's like $fa and $fn now.
As long as default matches current behaviour, I can't see anyone objecting
and it's like $fa and $fn now.
Ha, you wouldn't believe the amount of opposition I got to adding $preview
and I was doing the change myself, not asking others to do it.
On 14 September 2017 at 16:07, Gadgetmind lists@foxhill.co.uk wrote:
On 2017-09-14 15:59, Jordan Brown wrote:
Not that it wouldn't be a nuisance, but the straightforward thing to do
would be to change the .scad files to emit the "ECHO:" so that the
post-processing scripts wouldn't need to change.
Maybe ...
$echo_verbose = "quiet";
echo ("This won't print the ECHO: prefix.");
echo ("This will", $echo_verbose="normal");
echo ("This will also give file and line number", $echo_verbose="high");
or something.
As long as default matches current behaviour, I can't see anyone objecting
and it's like $fa and $fn now.
OpenSCAD mailing list
Discuss@lists.openscad.org
http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org