Go Back   MarcomCentral (PTI) and FusionPro User Communities > Software-Related Talk > The JavaScript Library > Graphic Rules

Notices

Reply
 
Thread Tools Search this Thread Display Modes
  #1  
Old July 5th, 2017, 05:05 PM
gdellaiera gdellaiera is offline
Regular Contributor
 
Join Date: Nov 2016
Posts: 78
Default Move Image in Graphic Frame

Does anyone know if it is possible to resize/reposition an image inside of a graphic frame? Formerly we were placing images into frames in InDesign and adjust them in there, then making our print files. Now we have created FusionPro templates to do all of this so that we do not have to create each file individually, with the help of galleries in DSF. The templates have different images (headshot, upper body, shoulders up) & I was wondering if there was a way I could just adjust the image in the template rather than having multiple galleries cropped in different manners. Thanks for any and all advice/help!
Reply With Quote
  #2  
Old July 5th, 2017, 05:59 PM
Dan Korn's Avatar
Dan Korn Dan Korn is online now
FusionPro Senior Engineer / Forum Moderator
 
Join Date: Aug 2008
Location: Chicago, IL
Posts: 4,369
Default Re: Move Image in Graphic Frame

This is what the Alignment and Scaling controls on the Graphic Frame Properties palette are for: You set where each variable graphic will be scaled, aligned, and clipped/cropped, relative to the frame.

That said, if you have a high degree of variability in your graphics, that may not be enough. But what specifically you need to do is hard to say in the abstract. A few actual pictures may be worth a thousand words.
__________________
Dan Korn
FusionPro Developer / JavaScript Guru / Forum Moderator
PTI Marketing Technologies | Printable | MarcomCentral
LinkedIn

I am a not a Support engineer, and this forum is not a substitute for Support. My participation on this forum is primarily as a fellow user (and a forum moderator). I am happy to provide help and answers to questions when I can; however, there is no guarantee that I, or anyone else on this forum, will be able to answer all questions or fix any problems. If I ask for files to clarify an issue, I might not be able to look at them personally. I am not able to answer private messages, emails, or phone calls unless they go through proper Support channels. Please direct any sales or pricing questions to your salesperson or inquiries@marcom.com.

Complex template-building questions, as well as all installation and font questions or problems, should be directed to FusionProSupport@marcom.com. Paid consulting work may be required to fulfill your template-building needs.

This is a publicly viewable forum. Please DO NOT post fonts, or other proprietary content, to this forum. Also, please DO NOT post any "live" data with real names, addresses, or any other personal, private, or confidential data.

Please include the specific versions of FusionPro, Acrobat, and your operating system in any problem reports or help requests. I recommend putting this information in your forum signature. Please also check your composition log (.msg) file for relevant error or warning messages.

Please post questions specific to the MarcomCentral Enterprise and Web-to-Print applications in the MarcomCentral forum. Click here to request access. Or contact your Business Relationship Manager (BRM/CPM) for assistance.

Please direct any questions specific to EFI's Digital StoreFront (DSF) to EFI support.

How To Ask Questions The Smart Way

The correct spellings are JavaScript, FusionPro, and MarcomCentral (each with two capital letters and no spaces). Acceptable abbreviations are JS, FP, and MC (or MCC). There is no "S" at the end of "Expression" or "Printable"! The name of the product is FusionPro, not "Fusion". "Java" is not is not the same as JavaScript.

Check out the JavaScript Guide and JavaScript Reference! FusionPro 8.0 and newer use JavaScript 1.7. Older versions use JavaScript 1.5.

return "KbwbTdsjqu!spdlt\"".replace(/./g,function(w){return String.fromCharCode(w.charCodeAt()-1)});
Reply With Quote
  #3  
Old July 6th, 2017, 05:55 AM
gdellaiera gdellaiera is offline
Regular Contributor
 
Join Date: Nov 2016
Posts: 78
Default Re: Move Image in Graphic Frame

Dan, what I am looking to do is 'drag & drop' with the placement of larger images in a small box, instead of the image sizing directly to the box. I don't have images as I haven't done this outside of InDesign bounding boxes. Does that make sense?
Reply With Quote
  #4  
Old July 6th, 2017, 10:30 AM
Dan Korn's Avatar
Dan Korn Dan Korn is online now
FusionPro Senior Engineer / Forum Moderator
 
Join Date: Aug 2008
Location: Chicago, IL
Posts: 4,369
Default Re: Move Image in Graphic Frame

Quote:
Originally Posted by gdellaiera View Post
Dan, what I am looking to do is 'drag & drop' with the placement of larger images in a small box, instead of the image sizing directly to the box. I don't have images as I haven't done this outside of InDesign bounding boxes. Does that make sense?
Sorry, no, it doesn't. I don't understand what you mean by "drag & drop," or, "a small box, instead of...the box." I would try setting up a job first and see how you can get it to work.
__________________
Dan Korn
FusionPro Developer / JavaScript Guru / Forum Moderator
PTI Marketing Technologies | Printable | MarcomCentral
LinkedIn

I am a not a Support engineer, and this forum is not a substitute for Support. My participation on this forum is primarily as a fellow user (and a forum moderator). I am happy to provide help and answers to questions when I can; however, there is no guarantee that I, or anyone else on this forum, will be able to answer all questions or fix any problems. If I ask for files to clarify an issue, I might not be able to look at them personally. I am not able to answer private messages, emails, or phone calls unless they go through proper Support channels. Please direct any sales or pricing questions to your salesperson or inquiries@marcom.com.

Complex template-building questions, as well as all installation and font questions or problems, should be directed to FusionProSupport@marcom.com. Paid consulting work may be required to fulfill your template-building needs.

This is a publicly viewable forum. Please DO NOT post fonts, or other proprietary content, to this forum. Also, please DO NOT post any "live" data with real names, addresses, or any other personal, private, or confidential data.

Please include the specific versions of FusionPro, Acrobat, and your operating system in any problem reports or help requests. I recommend putting this information in your forum signature. Please also check your composition log (.msg) file for relevant error or warning messages.

Please post questions specific to the MarcomCentral Enterprise and Web-to-Print applications in the MarcomCentral forum. Click here to request access. Or contact your Business Relationship Manager (BRM/CPM) for assistance.

Please direct any questions specific to EFI's Digital StoreFront (DSF) to EFI support.

How To Ask Questions The Smart Way

The correct spellings are JavaScript, FusionPro, and MarcomCentral (each with two capital letters and no spaces). Acceptable abbreviations are JS, FP, and MC (or MCC). There is no "S" at the end of "Expression" or "Printable"! The name of the product is FusionPro, not "Fusion". "Java" is not is not the same as JavaScript.

Check out the JavaScript Guide and JavaScript Reference! FusionPro 8.0 and newer use JavaScript 1.7. Older versions use JavaScript 1.5.

return "KbwbTdsjqu!spdlt\"".replace(/./g,function(w){return String.fromCharCode(w.charCodeAt()-1)});
Reply With Quote
  #5  
Old September 24th, 2019, 06:47 AM
ThePorge ThePorge is offline
Regular Contributor
 
Join Date: Aug 2011
Location: Georgia
Posts: 61
Default Re: Move Image in Graphic Frame

Dan,
Is there not a way to have the resource in a graphic frame be a specific size? eg. 77% or 7200px by 14400px. I can see how to do this for a inline graphic, but not in a Graphic frame.

fyi. I'm trying to get the results I want by using the OnRecordStart rule with the following:
"ChartBox".PDFBoundingBox = "ArtBox";
I have my graphic Frame named ChartBox, and verified the ArtBox in the pdf is the size I need....but this is not working either.

Last edited by ThePorge; September 24th, 2019 at 07:21 AM..
Reply With Quote
  #6  
Old September 24th, 2019, 10:24 AM
Dan Korn's Avatar
Dan Korn Dan Korn is online now
FusionPro Senior Engineer / Forum Moderator
 
Join Date: Aug 2008
Location: Chicago, IL
Posts: 4,369
Default Re: Move Image in Graphic Frame

Quote:
Originally Posted by ThePorge View Post
Dan,
Is there not a way to have the resource in a graphic frame be a specific size? eg. 77% or 7200px by 14400px. I can see how to do this for a inline graphic, but not in a Graphic frame.
I can think of a few ways:
  • Make the graphic frame the desired size and select Fill for the Scaling type.
  • Make the graphic frame the desired size and turn on Clip (the little scissors icon).
  • Make a text frame and put an inline graphic in it.
Quote:
Originally Posted by ThePorge View Post
fyi. I'm trying to get the results I want by using the OnRecordStart rule with the following:
"ChartBox".PDFBoundingBox = "ArtBox";
I have my graphic Frame named ChartBox, and verified the ArtBox in the pdf is the size I need....but this is not working either.
That's just setting a property on the string "ChartBox", not on a frame object. I think you want to do this in OnRecordStart instead:
Code:
var myFrame = FindGraphicFrame("ChartBox");
myFrame.SetGraphic("someFileName.pdf");
myFrame.PDFBoundingBox = "ArtBox";
Or possibly do this in a Graphic rule, then insert the rule into the frame:
Code:
var myResource = CreateResource("someFileName.pdf");
myResource.pdfbbox = "ArtBox";
return myResource;
Finally, I'll note that a Google search for "FusionPro pdfbbox" returns these as the top two hits:
http://forums.pti.com/showthread.php?t=2663
http://forums.pti.com/showthread.php?t=5095
That second one has examples almost exactly like what I've posted above. A search for "FusionPro PDFBoundingBox" returns that second one above as the first hit.
__________________
Dan Korn
FusionPro Developer / JavaScript Guru / Forum Moderator
PTI Marketing Technologies | Printable | MarcomCentral
LinkedIn

I am a not a Support engineer, and this forum is not a substitute for Support. My participation on this forum is primarily as a fellow user (and a forum moderator). I am happy to provide help and answers to questions when I can; however, there is no guarantee that I, or anyone else on this forum, will be able to answer all questions or fix any problems. If I ask for files to clarify an issue, I might not be able to look at them personally. I am not able to answer private messages, emails, or phone calls unless they go through proper Support channels. Please direct any sales or pricing questions to your salesperson or inquiries@marcom.com.

Complex template-building questions, as well as all installation and font questions or problems, should be directed to FusionProSupport@marcom.com. Paid consulting work may be required to fulfill your template-building needs.

This is a publicly viewable forum. Please DO NOT post fonts, or other proprietary content, to this forum. Also, please DO NOT post any "live" data with real names, addresses, or any other personal, private, or confidential data.

Please include the specific versions of FusionPro, Acrobat, and your operating system in any problem reports or help requests. I recommend putting this information in your forum signature. Please also check your composition log (.msg) file for relevant error or warning messages.

Please post questions specific to the MarcomCentral Enterprise and Web-to-Print applications in the MarcomCentral forum. Click here to request access. Or contact your Business Relationship Manager (BRM/CPM) for assistance.

Please direct any questions specific to EFI's Digital StoreFront (DSF) to EFI support.

How To Ask Questions The Smart Way

The correct spellings are JavaScript, FusionPro, and MarcomCentral (each with two capital letters and no spaces). Acceptable abbreviations are JS, FP, and MC (or MCC). There is no "S" at the end of "Expression" or "Printable"! The name of the product is FusionPro, not "Fusion". "Java" is not is not the same as JavaScript.

Check out the JavaScript Guide and JavaScript Reference! FusionPro 8.0 and newer use JavaScript 1.7. Older versions use JavaScript 1.5.

return "KbwbTdsjqu!spdlt\"".replace(/./g,function(w){return String.fromCharCode(w.charCodeAt()-1)});

Last edited by Dan Korn; September 24th, 2019 at 02:00 PM..
Reply With Quote
  #7  
Old September 24th, 2019, 02:31 PM
ThePorge ThePorge is offline
Regular Contributor
 
Join Date: Aug 2011
Location: Georgia
Posts: 61
Default Re: Move Image in Graphic Frame

Dan, Your guidance is always appreciated. I was trying to put the pdf box assignment in the graphic rule. I had mistakenly been trying to accomplish this by assigning the pdf box before the variable was a resource...

This....
Quote:
var myChart = 11; //Actually this var is also calculated earlier in the rule
myChart = myChart + "Row.pdf";
myChart.pdfbbox = "Artbox";
return Resource(myChart + "Row.pdf");
vs this....
Quote:
var myChart = 11; //Actually this var is also calculated earlier in the rule
myChart = Resource(myChart + "Row.pdf");
myChart.pdfbbox = "Artbox";
return myChart;
Reply With Quote
  #8  
Old September 24th, 2019, 04:05 PM
Dan Korn's Avatar
Dan Korn Dan Korn is online now
FusionPro Senior Engineer / Forum Moderator
 
Join Date: Aug 2008
Location: Chicago, IL
Posts: 4,369
Default Re: Move Image in Graphic Frame

Quote:
Originally Posted by ThePorge View Post
vs this....
Code:
var myChart = 11; //Actually this var is also calculated earlier in the rule
myChart = Resource(myChart + "Row.pdf");
myChart.pdfbbox = "Artbox";
return myChart;
Sure, though I think part of the confusion stemmed from the way you're using that same "myChart" variable to represent both a string/number and a resource object. And even though the code works, that potential for confusion is still there. I would do (something more like) this:
Code:
var myChart = 11; //Actually this var is also calculated earlier in the rule
var result = Resource(myChart + "Row.pdf");
result.pdfbbox = "Artbox";
return result;
I think that's a bit more maintainable.
__________________
Dan Korn
FusionPro Developer / JavaScript Guru / Forum Moderator
PTI Marketing Technologies | Printable | MarcomCentral
LinkedIn

I am a not a Support engineer, and this forum is not a substitute for Support. My participation on this forum is primarily as a fellow user (and a forum moderator). I am happy to provide help and answers to questions when I can; however, there is no guarantee that I, or anyone else on this forum, will be able to answer all questions or fix any problems. If I ask for files to clarify an issue, I might not be able to look at them personally. I am not able to answer private messages, emails, or phone calls unless they go through proper Support channels. Please direct any sales or pricing questions to your salesperson or inquiries@marcom.com.

Complex template-building questions, as well as all installation and font questions or problems, should be directed to FusionProSupport@marcom.com. Paid consulting work may be required to fulfill your template-building needs.

This is a publicly viewable forum. Please DO NOT post fonts, or other proprietary content, to this forum. Also, please DO NOT post any "live" data with real names, addresses, or any other personal, private, or confidential data.

Please include the specific versions of FusionPro, Acrobat, and your operating system in any problem reports or help requests. I recommend putting this information in your forum signature. Please also check your composition log (.msg) file for relevant error or warning messages.

Please post questions specific to the MarcomCentral Enterprise and Web-to-Print applications in the MarcomCentral forum. Click here to request access. Or contact your Business Relationship Manager (BRM/CPM) for assistance.

Please direct any questions specific to EFI's Digital StoreFront (DSF) to EFI support.

How To Ask Questions The Smart Way

The correct spellings are JavaScript, FusionPro, and MarcomCentral (each with two capital letters and no spaces). Acceptable abbreviations are JS, FP, and MC (or MCC). There is no "S" at the end of "Expression" or "Printable"! The name of the product is FusionPro, not "Fusion". "Java" is not is not the same as JavaScript.

Check out the JavaScript Guide and JavaScript Reference! FusionPro 8.0 and newer use JavaScript 1.7. Older versions use JavaScript 1.5.

return "KbwbTdsjqu!spdlt\"".replace(/./g,function(w){return String.fromCharCode(w.charCodeAt()-1)});
Reply With Quote
Reply

Tags
fusionpro, galleries, images

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -7. The time now is 03:29 PM.


Powered by vBulletin® Version 3.8.4
Copyright ©2000 - 2019, Jelsoft Enterprises Ltd.
(c) 2011, PTI Marketing Technologies™, Inc.