Jump to content

ThomasLewis

Members
  • Posts

    298
  • Joined

  • Days Won

    11

Posts posted by ThomasLewis

  1. Now, when you have time can you explain what parts of the rule made it happen and how?

     

    There's a lot of good information in the links in Dan's signature. You might take a look at some of those and also learn about regular expressions. They can get quite complex depending on what you want to do.

     

    Basically in this case we are just finding any digit 0-9 and replacing it with the ascii code for the oldstyle number.

     

    Example for this specific case with Minion Pro:

    (These should have an & in front of the # but the forums seem to hate this)

    0 = #63280;

    1 = #63281;

    2 = #63282;

    etc.

     

    The $1 is a placeholder for what the replacement found, ie if it found a 3 then $1 is a 3.

    As I mentioned earlier, this may not always be the case depending on where the font creator decides to put those figures.

  2. Can I apply this to another rule for the ask amount variables?

     

    Sure. The only thing I would caution you on is this is specific to Minion Pro. It will probably work for other Adobe Pro fonts assuming they put the numerals in the same spot.

     

    For future readers of this thread:

    As Dan mentioned in the thread he pointed to earlier, there is no standard so it is impossible to predict where the numerical characters are. If you were to use this for other fonts you would need to find the unicode area where they are located using a program like Character Map and then get the ascii values. In this particular case it's a fortunate coincidence (or well planned) that the last character of the ascii value is the same as the numerical value, resulting in very a straight forward regex replacement.

  3. Go back and look at my post with the script in it. It needs to be exactly as indicated. Notice how your post where you quoted me has the code messed up. If you copied and pasted from that, then it won't work.

    oldstyle-numerals.jpg.d7b3f9d39078bbf3469b8eaffcda9945.jpg

  4. OK, now before I try it let me make sure I have all my ducks lined up...

     

    Just to make sure you a clear on what I am trying to accomplish, I have rambled on in the post and it may be confusing.

     

    I have a data field called [Delivery Address] which contains the street number and name.

     

    The customer is using minion pro and the fonts are old style Tabular Oldstyle.

     

    How will I set the font? Do I set it in the text editor at the variable name?

     

    Create a new rule called "rule_DeliveryAddress". Paste the code in as indicated but change the Field to Field("Delivery Address"). Check the box that says "Treat returned strings as tagged text".

     

    Open text frame where you want the changed text and insert the «rule_DeliveryAddress» variable. Highlight it and change the font to Minion Pro.

     

    Go to the compose dialog and the Advanced tab. Turn off the box that says "Limit processing to Latin-1 text". Let me know how it works.

  5. Give this rule a shot:

     

    return Field("Address").replace(/([0-9])/g, "ᢸ$1;").replace(/\s/g, " ");

     

    You will need to turn on "Treat returned strings as tagged text" in the rule and also in the compose window, under the Advanced tab, turn off "Limit processing to Latin-1 text".

     

    Note: the second replace is only needed if you have have digits separated by spaces, ie "564 897 S. Street". For whatever reason Fusion pushes the digits together too closely and using non breaking spaces fixes that.

  6. This is hard to test without input file and resources but you may be able to achieve the result you want by doing the following:

     

    1. Go to menu FusionPro / Data Definition / Input Options / Edit Fields then change PDF File Name to Type Graphic
    2. Add a blank page in your template before page 1
    3. Create a graphic frame covering that page
    4. Set the Field or Rule in the Graphic Frame palette to be PDF File Name
    5. Move what used to be body page 1 to body page 3
    6. You probably need to move the small text frame in the upper right to page 1
    7. Open the Rule AlexMarshall and change var pgnbr = 1 to var pgnbr = 2

     

    What should happen is now page 1 will be static on page 1. Page 2 will be your blank. Page 3 and any following pages will be the overflow starting with page 2 of the input PDF.

  7. Attached is "a" way to do this. There are probably dozens of ways to get the end result but this would be my approach. You should be able to just unpack the zip and hit Compose to test it.

     

    A couple things to note.

    There are no conventional text rules in the example. All the magic happens in the two callbacks.

    There is no input file. It is set to "None".

    You are only composing one record, it is being repeated and changed based on the external file.

    ExternalDataFile_Nup.zip

  8. I am also familiar with the Auto Fill feature but that tiny link is hardly noticeable, not to mention it allows the users to edit and re-save the list, which is not what I am looking for.

     

    That's the method I use for clients who need the ability to edit the addresses. So long as the product is set to just show the Corporate Addresses I'm not aware of any way the end user can overwrite that list.

     

    You can use a bit of CSS in your Custom Content Footer to globally change the look of the link. Here's an example:

    <style type="text/css">
    .SelectSavedContentPrompt a {
    color: #FFF;
    font-weight: bold;
    font-size: 14px;
    background-color:#259542;
    display: inline-block;
    padding: 4px 6px;
    }
    </style>

     

    You can also change the "Autofill Options" wording on the button to something more intuitive using the Portal Editor.

     

     

    Alternatively, if you maintain your customers address list, then a much better method is to use an external data file and point your templates to that. The end user cannot alter the address but often times that's for the best.

  9. What you are looking to do is referred to as arbitrary chunking. You can search the forums for plenty of examples. I've attached a 20 up sample that you should be able to adapt.

     

    The key components are two things you need to add to OnRecordStart:

     

    FusionPro.Composition.chunksBreakStacks = true;
    
    if (FieldChanged("Group"))
       FusionPro.Composition.StartNewStack();

     

    Where "Group" is whatever field designates a new imposition sheet.

    arbitrary-chunking-sample.zip

  10. I have not used this so no guarantees here.

     

    First make sure the page_width__ field has a lower sort order number than the page_height__ field.

    Put the following script in the Note part of the page_width__ field. Make sure the doc_width and doc_height numbers are correct for your template.

     

    <script type="text/javascript">
    var doc_width = 8.5;
    var doc_height = 11;
    
    document.getElementById("page_width__").onblur = calc;
    function calc() {
    document.getElementById("page_height__").value = parseFloat(this.value) * (doc_height / doc_width);}
    </script>
    

     

    This should automatically fill out the page_height__ field when you click out of it. You will likely want to set that field to be hidden before publishing the form.

     

    Let me know how it works out.

  11. I have attached my template I am trying to test. Is there something I need to change somewhere to get the full slipsheet?

     

    In the imposition file, try setting your bleed to 10" and under layout, your horizontal spacing to negative 20". You wont see the left page because it's covered with the bleed grid but it will show up on the output.

     

    For what it's worth, this bug plagues me as well. Fortunately this bleed workaround seems to work a lot of the time.

  12. Thanks.

    I'm not seeing this. Does this happen with all jobs? Can you reproduce it with the Tutorials? Are you chunking (composing to multiple output files)? Can you give me any specific information as to how to reproduce this?

     

    I seem to be having this issue as well. It happens when an imposition is applied.

     

    This was tested by creating a blank PDF, input file set to none, record range set from: 1 to 1. Composed with an imposition, locally and to the API. Both versions append a 1. Turn the imposition off and the 1 goes away.

  13. The span tag has a Shading attribute. If you want to change everything globally you can do something like this in OnRecordStart:

     

    for (var f in FusionPro.Fields)
    {
       var text = '<span color="PANTONE ###" shading="50">' + FusionPro.Fields[f] + '</span>';
       FusionPro.Composition.AddVariable(f, text, true)
    }
    

     

    It's probably bad form because the span tag is wrapping paragraph tags, but it seems to work okay.

     

    Sources:

    http://forums.printable.com/showthread.php?p=10580

    http://forums.pti.com/showpost.php?p=1819

  14. It certainly appears the imposition is applying clipping to the entire document, slipsheets included. Fortunately it includes bleed. So by adding a 10 inch bleed :eek: to the document and then discarding it on the layout itself, it opens up the clipping path to a large enough area to show the entire slipsheet.

     

    Obviously this is not a fix, but it does work in this one case where the file didn't actually have bleed.

     

    Attached is the revised imposition file so you can see what I mean. And yes, I realize this is an insane way to get around it.

    Slipsheet_Test_Imposition_bleedfix.fpi

  15. I'm having the exact same issue as indicated in the original post. I'm attaching a sample numbering job (no input file needed) where the slipsheet should be inserted every stack of 10. Instead of showing the entire sheet, it clips the artwork to the trim size indicated in the imposition file. I would love to know if there is a workaround for this.

    Slipsheet_Test_FP.pdf

    Output Sample.pdf

    Slipsheet_Test_Imposition.fpi

  16. When you click the text box to open the Variable Text Editor you will see a "Tabs..." button. Make sure you select all the text or the whole line the rule is on. With it highlighted, click the button and you can change the settings in there.

     

    You can also do it programmatically by using the paragraph <p> tag which is outlined in the TagsRefGuide PDF under markup tags.

×
×
  • Create New...