Back

If your email is not recognized and you believe it should be, please contact us.

Forum Replies Created

Viewing 14 posts - 61 through 75 (of 339 total)
  • Author
    Posts
  • Peter Kahrel
    Participant

    \K is for positive lookbehind only as far as I know. The classic lookbehind doesn’t handle variable-length arguments, so you can’t use operators like + and *. But in your case you can enumerate the options, in which case you can use the classic lookbehind:

    ((?<!ABCDE)(?<!FGH))XYZ

    in reply to: Text indent issue #1238936
    Peter Kahrel
    Participant

    The spaces that you see between the left edge of the text frame and the first characters of the two paragraph (the B and the F) are the left sidebearings of the characters: that space is part of the character the way it’s defined in the font. Therefore you can’t use left indent or whatever. The only way to get align the visible part of the letters at the frame’s edge is to insert an innocent and invisible character such as a discretionary hyphen before the first letter and apply kerning between the two. You can automate that, see

    https://creativepro.com/files/kahrel/indesign/kern.html#kern_first_character

    P.

    in reply to: TOC, erase the fullstop? #1238774
    Peter Kahrel
    Participant

    Look again at David’s expression, where he has a code for ‘any punctuation’. Combine that with yours and you get [[:punct:]](?=~%)

    in reply to: JavaScript for InDesign article Simple Script Runner #1238723
    Peter Kahrel
    Participant

    Just for the record: Edward discovered that it was a problem with InDesign’s preferences. After deleting them the scripts worked as expected.

    in reply to: JavaScript for continuously numbering documents #1237884
    Peter Kahrel
    Participant

    Excellent!

    in reply to: JavaScript for continuously numbering documents #1237745
    Peter Kahrel
    Participant

    File received in good order, thank you. After I opened the book and all its documents (apart from the first two, which shouldn’t change) I ran the one-line script and all documents were renumbered correctly. I’ll send a screenshot of the before and after books to your email, I can’t attach it here. You did you open the documents, did you not?

    P.

    in reply to: JavaScript for continuously numbering documents #12372744
    Peter Kahrel
    Participant

    I can’t imagine that corruption plays a role. If any of your documents were corrupt, InDesign wouldn’t be able to open it or if it did, would probably crash.

    If you zip up your files and send then to pkahrel@gmail.com I’ll have a look.

    P.

    in reply to: JavaScript for continuously numbering documents #1237274
    Peter Kahrel
    Participant

    I can’t imagine that corruption plays a role. If any of your documents were corrupt, InDesign wouldn’t be able to open it or if it did, would probably crash.

    If you zip up your files and send then to pkahrel@gmail.com I’ll have a look.

    P.

    in reply to: Indesign to layers PSD #12372044
    Peter Kahrel
    Participant

    InDesign can’t export to Photoshop. You can try via PDF or EPS/AI, but what that does to layers I’ve no idea.

    in reply to: JavaScript for continuously numbering documents #12371844
    Peter Kahrel
    Participant

    But the one you’ve been using changes the documents to number automatically… You are using this one, correct?

    app.documents.everyItem().sections[0].continueNumbering = true;

    And it’s the page numbers that should be targeted, not any other type of numbering — correct?

    P.

    in reply to: JavaScript for continuously numbering documents #12370444
    Peter Kahrel
    Participant

    One last thing you can try: use the script to change the document to automatic numbering, and save all the documents. Then in the book panel’s flyout, select Update Numbering, then All Numbers (or Update Page and Section Numbers, whichever you prefer). Does that work?

    in reply to: JavaScript for continuously numbering documents #1236994
    Peter Kahrel
    Participant

    By the way, Edward, coming back to your earlier query about saving documents: the script only changes the setting in the Numbering & Section Options window, nothing else. You need to save all the documents yourself.

    P.

    in reply to: JavaScript for continuously numbering documents #1236984
    Peter Kahrel
    Participant

    Strange. After running the script, when you go to a document’s Numbering & Section Options window, which button is selected? ‘Automatic Page Numbering’ or ‘Start Page Numbering at’? Please check more than one document.

    in reply to: JavaScript for continuously numbering documents #1236964
    Peter Kahrel
    Participant

    I think I understand the problem: you need to enable the book’s automatic page numbering: in the book’s fly-out menu (click the three small horizontal lines at the top-right of the book panel), select Book Page Numbering Options and check the automatic page numbering. That should do the trick.

    I could add that as a second line to the script, but then it would no longer be a one-liner!

Viewing 14 posts - 61 through 75 (of 339 total)