Image scaling Macro

Need help, or want to share a macro? Post here!
Forum rules
Be nice to others! Respect the FreeCAD code of conduct!
Jee-Bee
Veteran
Posts: 2566
Joined: Tue Jun 16, 2015 10:32 am
Location: Netherlands

Re: Image scaling Macro

Post by Jee-Bee »

keithg wrote:I registered on this forum simply to say thank you for this macro. I have to use reference drawings a lot and this will save me sooo much time. Well done.
Welcome at the forum!!
jcr
Posts: 6
Joined: Sat Mar 04, 2017 10:38 pm

Re: Image scaling Macro

Post by jcr »

Hi, I am new to this and I thought this Macro would be useful but I am not sure if I am installing it or using it correctly. It says I am getting a Syntax Error when I try executing it 48,73 not sure if anyone had that issue?
chrisb
Veteran
Posts: 54164
Joined: Tue Mar 17, 2015 9:14 am

Re: Image scaling Macro

Post by chrisb »

Perhaps it is a locale problem, did you try entering the value as 48.73
A Sketcher Lecture with in-depth information is available in English, auf Deutsch, en français, en español.
jcr
Posts: 6
Joined: Sat Mar 04, 2017 10:38 pm

Re: Image scaling Macro

Post by jcr »

No i just copy and pasted the macro code into the macro creation part. I have also tried the downloaded macro file and still the same error.

Does the file need to be in a specific directly?
chrisb
Veteran
Posts: 54164
Joined: Tue Mar 17, 2015 9:14 am

Re: Image scaling Macro

Post by chrisb »

The file has to be in your macro directory which can be configured in Preferences->General->Macro->Macro path.
A Sketcher Lecture with in-depth information is available in English, auf Deutsch, en français, en español.
jcr
Posts: 6
Joined: Sat Mar 04, 2017 10:38 pm

Re: Image scaling Macro

Post by jcr »

which I did define since my macro directory is not the default location.
User avatar
sliptonic
Veteran
Posts: 3459
Joined: Tue Oct 25, 2011 10:46 pm
Location: Columbia, Missouri
Contact:

Re: Image scaling Macro

Post by sliptonic »

This macro is broken. It looks like most of the code is completely missing.
It ends on line 47 with a missing close ')' which is why it is giving the error noted.

Is there an updated version of this macro somewhere that actually works?

I really think this is necessary functionality for the image workbench. Perhaps it should be fixed up and included directly.

Also, the image workbench really needs different icons for the two tools on the toolbar.
User avatar
easyw-fc
Veteran
Posts: 3633
Joined: Thu Jul 09, 2015 9:34 am

Re: Image scaling Macro

Post by easyw-fc »

sliptonic wrote: Tue May 08, 2018 2:10 pm This macro is broken. It looks like most of the code is completely missing.
It ends on line 47 with a missing close ')' which is why it is giving the error noted.

Is there an updated version of this macro somewhere that actually works?

I really think this is necessary functionality for the image workbench. Perhaps it should be fixed up and included directly.

Also, the image workbench really needs different icons for the two tools on the toolbar.
in the page there is a download link (I know it is a bit hidden :D )
http://forum.freecadweb.org/download/file.php?id=19542

link.png
link.png (18.31 KiB) Viewed 1193 times
User avatar
sliptonic
Veteran
Posts: 3459
Joined: Tue Oct 25, 2011 10:46 pm
Location: Columbia, Missouri
Contact:

Re: Image scaling Macro

Post by sliptonic »

Ok. But when the macro is installed from the Addon Manager, the only thing installed is the partial snippet visible on the Wiki page.
User avatar
sliptonic
Veteran
Posts: 3459
Joined: Tue Oct 25, 2011 10:46 pm
Location: Columbia, Missouri
Contact:

Re: Image scaling Macro

Post by sliptonic »

Line 47 has a pipe character that seems to be breaking the code template.
Post Reply