13 Replies Latest reply on Sep 6, 2009 5:57 AM by Harbs.

    TextStyleRAnges [CS4]

    Fred Goldman Level 3

      Am I the only one that doesn't see a way to search the forums?


      Anyway, I am trying to figure out why when I run this little piece of code it will give me the leading for all the leading of the textStyleRanges of the selected paragraph AND the leading of the first textStyleRAnge of the next paragraph. Has anyone else noticed this? I tried this in CS3 and it works as expected.


          myPar = app.selection[0].paragraphs[0];
          var myRanges = myPar.textStyleRanges.everyItem().getElements();
          for(var j = 0;myRanges.length>j;j++){