Skip navigation
Currently Being Moderated

InDesign Server CS4 issue with baseline alignment

Jun 19, 2012 2:35 PM

Hi all,

 

I need to turn baseline alignment off for every text frame. I used alignToBaseline = false until I learnt that this property isn't available in teh IDS CS4 DOM. I was adviced to use gridAlignment instead but it's CS5+ only.

 

So my question is how do we set baseline alignment off for textframes in InDesign Server CS4 ?

 

Thanks in advance,

 

Loic

 
Replies
  • Currently Being Moderated
    Jun 20, 2012 12:48 AM   in reply to Loic_aigon

    @Loic – My first reaction after reading that was: "I can't believe that…"
    "alignToBaseline" is not available for "story" objects in InDesign Server CS4?

     

    But, unfortunately, you could be damn right. Just checked for it in Jongwares' chm DOM representation of InDesign CS5 Server. It's missing there as well.

    That's a real drag!

     

    Sorry, but I cannot help any further…

     

    Uwe

     
    |
    Mark as:
  • Currently Being Moderated
    Jun 20, 2012 5:41 AM   in reply to Loic_aigon

    Well, I'll be... !

     

    You are right. It's missing!

     

    And no one has noticed for years...

     

    I'll try to log this as a bug.

     

    Harbs

     
    |
    Mark as:
  • Currently Being Moderated
    Jun 25, 2012 7:22 AM   in reply to Loic_aigon

    This is perhaps a bit of a longshot, but does "gridAlignFirstLineOnly" work for you instead? I'm just looking into this issue now, though I should warn you that I'm new to the InDesign DOM!

     

    Best wishes,

     

    Louis

     
    |
    Mark as:
  • Currently Being Moderated
    Jun 25, 2012 7:39 AM   in reply to lomorgan

    That's actually not a bad thought!

     

    Text.gridAlignment = GridAlignment.ALIGN_BASELINE does the same thing as:

    Text.alignToBaseline = true;

     

    (gridAlignFirstLineOnly is a bit different)

     

    Unfortunately, that property was introduced in the Roman version in CS5.

     

    At least we have a solution for CS5 and later...

     
    |
    Mark as:
  • Currently Being Moderated
    Jun 25, 2012 8:28 AM   in reply to Harbs.

    "in the Roman version" seems to be the critical thing here - I can see it in the Japanese feature set in CS 4 server, not sure if that's any help though.

     
    |
    Mark as:
  • Currently Being Moderated
    Jun 25, 2012 11:17 AM   in reply to lomorgan

    Good call.

     

    I forgot that Server had the J DOM features...

     

    Yes. That should work in CS4 as well.

     

    Harbs

     
    |
    Mark as:
  • Currently Being Moderated
    Jun 25, 2012 11:55 PM   in reply to Harbs.

    We've been using that gridAlignment for years on CS4 Server. To make your code run everywhere, use the properties property like below - it ignores unsupported properties.

     

    function setAlignToBaseline(aText,aValue)

    {

         if( aValue ) {

              aText.properties = {

                   alignToBaseline: true,

                   gridAlignment: GridAlignment.ALIGN_BASELINE

              }

         } else {

              aText.properties = {

                   alignToBaseline: false,

                   gridAlignment: GridAlignment.NONE

              }

         }

    }

     
    |
    Mark as:
  • Currently Being Moderated
    Jun 26, 2012 12:12 AM   in reply to Dirk Becker

    Nice.

     

    GridAlignment.ALIGN_BASELINE doesn't throw an undefined error on desktop?

     

    Harbs

     
    |
    Mark as:
  • Currently Being Moderated
    Jun 26, 2012 11:26 AM   in reply to Harbs.

    That's a general feature of the "properties" property - it only throws if none of the provided properties has a match.

     

    Dirk

     
    |
    Mark as:
  • Currently Being Moderated
    Jun 26, 2012 11:33 AM   in reply to Dirk Becker

    Yes. I know that, but isn't GridAlignment itself undefined on Desktop?

     

    Harbs

     
    |
    Mark as:

More Like This

  • Retrieving data ...

Bookmarked By (0)

Answers + Points = Status

  • 10 points awarded for Correct Answers
  • 5 points awarded for Helpful Answers
  • 10,000+ points
  • 1,001-10,000 points
  • 501-1,000 points
  • 5-500 points