3 Replies Latest reply on Sep 26, 2016 9:17 AM by Jarda Bereza

    Matching a Layer's Type Size to Its Paragraph Style Size with JavaScript?

    walter-fba

      Background

      we've been working on a pretty big project with a lot of moving parts. It has dozens of different typographical styles, and when we change a style in one place, there are several other places we want it changed. Naturally, using paragraph and character styles are the best choice for this.

       

      Our trouble: if you transform a type layer using the bounding box, the paragraph and character styles are irreversibly scaled to the percentage at which the layer was transformed. So for example, if a paragraph style is 24pt, and the layer is scaled by 130%, the type size will be 31.2pt. But the paragraph style remains 24pt. If the paragraph style is changed to say, 18pt, the size of the type in the scaled layer will now be 23.4pt.

       

      If there were an easy way to revert the transformation on a layer, this wouldn't be a problem... but Photoshop doesn't have a way to do that.

       

      My idea

      Transform a layer to its paragraph style's point size divided by the layer's point size. (e.g. 24 / 31.2 = 0.7692307692).

       

      My question

      Is this possible? I haven't found any documentation on how to get the point size of the paragraph style applied to a layer.

        • 1. Re: Matching a Layer's Type Size to Its Paragraph Style Size with JavaScript?
          Jarda Bereza Level 4

          Original size before transformation is stored in textLayer datastrucuture.

          Data structure looks like this. Anyway I am using jamText framework for storing all properties in variable. Without framework you need use actionDescriptor system to get/set these values if you can't see/set them in standart DOM via extension script toolkit. (app.activeDocument.activeLayer.textItem.-somewhere-)

           

          You could be interested also in baselineShift, because behavior could be similar if you scale layer.

           

          Structure is very similar for "paragraphStyle" too.

          2016-09-17_094134.jpg

          1 person found this helpful
          • 2. Re: Matching a Layer's Type Size to Its Paragraph Style Size with JavaScript?
            walter-fba Level 1

            Thanks Jarda. (For posterity: Jarda is talking about JSON Action Manager.) I want to avoid installing anything extra in order to run the script. It’s going to be used on multiple computers within our studio, and I don’t want to have to install JAM on every one.

             

            Do you know if a way to achieve this without JAM?

            • 3. Re: Matching a Layer's Type Size to Its Paragraph Style Size with JavaScript?
              Jarda Bereza Level 4

              You need to write very human non-friendly code. I don't have yet experiences to do that. You will waste a lot of time if you don't use framework, because with framework it is very simple. You can include framework inside JSX file. You will have still one file and you don't need install anything. Just add minified framework code on the very first lines in your JSX file.

               

              Most simple thing is use jamText like this.

              var myTextLayer = jamText.getLayerText();
              myTextLayer.something.something[index].something = "yourValue"; //size, color, anything you want... myTextLayer is standart JS object.
              jamText.getLayerText(myTextLayer);
              

               

              Or if you want classic way you can try modify this code recorded with script listener.

              var idMk = charIDToTypeID( "Mk  " );
                  var desc14 = new ActionDescriptor();
                  var idnull = charIDToTypeID( "null" );
                      var ref2 = new ActionReference();
                      var idTxLr = charIDToTypeID( "TxLr" );
                      ref2.putClass( idTxLr );
                  desc14.putReference( idnull, ref2 );
                  var idUsng = charIDToTypeID( "Usng" );
                      var desc15 = new ActionDescriptor();
                      var idTxt = charIDToTypeID( "Txt " );
                      desc15.putString( idTxt, """test""" );
                      var idwarp = stringIDToTypeID( "warp" );
                          var desc16 = new ActionDescriptor();
                          var idwarpStyle = stringIDToTypeID( "warpStyle" );
                          var idwarpStyle = stringIDToTypeID( "warpStyle" );
                          var idwarpNone = stringIDToTypeID( "warpNone" );
                          desc16.putEnumerated( idwarpStyle, idwarpStyle, idwarpNone );
                          var idwarpValue = stringIDToTypeID( "warpValue" );
                          desc16.putDouble( idwarpValue, 0.000000 );
                          var idwarpPerspective = stringIDToTypeID( "warpPerspective" );
                          desc16.putDouble( idwarpPerspective, 0.000000 );
                          var idwarpPerspectiveOther = stringIDToTypeID( "warpPerspectiveOther" );
                          desc16.putDouble( idwarpPerspectiveOther, 0.000000 );
                          var idwarpRotate = stringIDToTypeID( "warpRotate" );
                          var idOrnt = charIDToTypeID( "Ornt" );
                          var idHrzn = charIDToTypeID( "Hrzn" );
                          desc16.putEnumerated( idwarpRotate, idOrnt, idHrzn );
                      var idwarp = stringIDToTypeID( "warp" );
                      desc15.putObject( idwarp, idwarp, desc16 );
                      var idTxtC = charIDToTypeID( "TxtC" );
                          var desc17 = new ActionDescriptor();
                          var idHrzn = charIDToTypeID( "Hrzn" );
                          var idPrc = charIDToTypeID( "#Prc" );
                          desc17.putUnitDouble( idHrzn, idPrc, 18.228404 );
                          var idVrtc = charIDToTypeID( "Vrtc" );
                          var idPrc = charIDToTypeID( "#Prc" );
                          desc17.putUnitDouble( idVrtc, idPrc, 36.067708 );
                      var idPnt = charIDToTypeID( "Pnt " );
                      desc15.putObject( idTxtC, idPnt, desc17 );
                      var idtextGridding = stringIDToTypeID( "textGridding" );
                      var idtextGridding = stringIDToTypeID( "textGridding" );
                      var idNone = charIDToTypeID( "None" );
                      desc15.putEnumerated( idtextGridding, idtextGridding, idNone );
                      var idOrnt = charIDToTypeID( "Ornt" );
                      var idOrnt = charIDToTypeID( "Ornt" );
                      var idHrzn = charIDToTypeID( "Hrzn" );
                      desc15.putEnumerated( idOrnt, idOrnt, idHrzn );
                      var idAntA = charIDToTypeID( "AntA" );
                      var idAnnt = charIDToTypeID( "Annt" );
                      var idantiAliasSharp = stringIDToTypeID( "antiAliasSharp" );
                      desc15.putEnumerated( idAntA, idAnnt, idantiAliasSharp );
                      var idbounds = stringIDToTypeID( "bounds" );
                          var desc18 = new ActionDescriptor();
                          var idLeft = charIDToTypeID( "Left" );
                          var idPxl = charIDToTypeID( "#Pxl" );
                          desc18.putUnitDouble( idLeft, idPxl, 0.000000 );
                          var idTop = charIDToTypeID( "Top " );
                          var idPxl = charIDToTypeID( "#Pxl" );
                          desc18.putUnitDouble( idTop, idPxl, -96.204102 );
                          var idRght = charIDToTypeID( "Rght" );
                          var idPxl = charIDToTypeID( "#Pxl" );
                          desc18.putUnitDouble( idRght, idPxl, 278.445313 );
                          var idBtom = charIDToTypeID( "Btom" );
                          var idPxl = charIDToTypeID( "#Pxl" );
                          desc18.putUnitDouble( idBtom, idPxl, 34.833984 );
                      var idbounds = stringIDToTypeID( "bounds" );
                      desc15.putObject( idbounds, idbounds, desc18 );
                      var idboundingBox = stringIDToTypeID( "boundingBox" );
                          var desc19 = new ActionDescriptor();
                          var idLeft = charIDToTypeID( "Left" );
                          var idPxl = charIDToTypeID( "#Pxl" );
                          desc19.putUnitDouble( idLeft, idPxl, 10.875000 );
                          var idTop = charIDToTypeID( "Top " );
                          var idPxl = charIDToTypeID( "#Pxl" );
                          desc19.putUnitDouble( idTop, idPxl, -77.000000 );
                          var idRght = charIDToTypeID( "Rght" );
                          var idPxl = charIDToTypeID( "#Pxl" );
                          desc19.putUnitDouble( idRght, idPxl, 266.755859 );
                          var idBtom = charIDToTypeID( "Btom" );
                          var idPxl = charIDToTypeID( "#Pxl" );
                          desc19.putUnitDouble( idBtom, idPxl, 1.000000 );
                      var idboundingBox = stringIDToTypeID( "boundingBox" );
                      desc15.putObject( idboundingBox, idboundingBox, desc19 );
                      var idtextShape = stringIDToTypeID( "textShape" );
                          var list1 = new ActionList();
                              var desc20 = new ActionDescriptor();
                              var idTEXT = charIDToTypeID( "TEXT" );
                              var idTEXT = charIDToTypeID( "TEXT" );
                              var idPnt = charIDToTypeID( "Pnt " );
                              desc20.putEnumerated( idTEXT, idTEXT, idPnt );
                              var idOrnt = charIDToTypeID( "Ornt" );
                              var idOrnt = charIDToTypeID( "Ornt" );
                              var idHrzn = charIDToTypeID( "Hrzn" );
                              desc20.putEnumerated( idOrnt, idOrnt, idHrzn );
                              var idTrnf = charIDToTypeID( "Trnf" );
                                  var desc21 = new ActionDescriptor();
                                  var idxx = stringIDToTypeID( "xx" );
                                  desc21.putDouble( idxx, 1.000000 );
                                  var idxy = stringIDToTypeID( "xy" );
                                  desc21.putDouble( idxy, 0.000000 );
                                  var idyx = stringIDToTypeID( "yx" );
                                  desc21.putDouble( idyx, 0.000000 );
                                  var idyy = stringIDToTypeID( "yy" );
                                  desc21.putDouble( idyy, 1.000000 );
                                  var idtx = stringIDToTypeID( "tx" );
                                  desc21.putDouble( idtx, 0.000000 );
                                  var idty = stringIDToTypeID( "ty" );
                                  desc21.putDouble( idty, 0.000000 );
                              var idTrnf = charIDToTypeID( "Trnf" );
                              desc20.putObject( idTrnf, idTrnf, desc21 );
                              var idrowCount = stringIDToTypeID( "rowCount" );
                              desc20.putInteger( idrowCount, 1 );
                              var idcolumnCount = stringIDToTypeID( "columnCount" );
                              desc20.putInteger( idcolumnCount, 1 );
                              var idrowMajorOrder = stringIDToTypeID( "rowMajorOrder" );
                              desc20.putBoolean( idrowMajorOrder, true );
                              var idrowGutter = stringIDToTypeID( "rowGutter" );
                              var idPxl = charIDToTypeID( "#Pxl" );
                              desc20.putUnitDouble( idrowGutter, idPxl, 0.000000 );
                              var idcolumnGutter = stringIDToTypeID( "columnGutter" );
                              var idPxl = charIDToTypeID( "#Pxl" );
                              desc20.putUnitDouble( idcolumnGutter, idPxl, 0.000000 );
                              var idSpcn = charIDToTypeID( "Spcn" );
                              var idPxl = charIDToTypeID( "#Pxl" );
                              desc20.putUnitDouble( idSpcn, idPxl, 0.000000 );
                              var idframeBaselineAlignment = stringIDToTypeID( "frameBaselineAlignment" );
                              var idframeBaselineAlignment = stringIDToTypeID( "frameBaselineAlignment" );
                              var idalignByAscent = stringIDToTypeID( "alignByAscent" );
                              desc20.putEnumerated( idframeBaselineAlignment, idframeBaselineAlignment, idalignByAscent );
                              var idfirstBaselineMinimum = stringIDToTypeID( "firstBaselineMinimum" );
                              var idPxl = charIDToTypeID( "#Pxl" );
                              desc20.putUnitDouble( idfirstBaselineMinimum, idPxl, 0.000000 );
                              var idbase = stringIDToTypeID( "base" );
                                  var desc22 = new ActionDescriptor();
                                  var idHrzn = charIDToTypeID( "Hrzn" );
                                  desc22.putDouble( idHrzn, 0.000000 );
                                  var idVrtc = charIDToTypeID( "Vrtc" );
                                  desc22.putDouble( idVrtc, 0.000000 );
                              var idPnt = charIDToTypeID( "Pnt " );
                              desc20.putObject( idbase, idPnt, desc22 );
                          var idtextShape = stringIDToTypeID( "textShape" );
                          list1.putObject( idtextShape, desc20 );
                      desc15.putList( idtextShape, list1 );
                      var idTxtt = charIDToTypeID( "Txtt" );
                          var list2 = new ActionList();
                              var desc23 = new ActionDescriptor();
                              var idFrom = charIDToTypeID( "From" );
                              desc23.putInteger( idFrom, 0 );
                              var idT = charIDToTypeID( "T   " );
                              desc23.putInteger( idT, 5 );
                              var idTxtS = charIDToTypeID( "TxtS" );
                                  var desc24 = new ActionDescriptor();
                                  var idstyleSheetHasParent = stringIDToTypeID( "styleSheetHasParent" );
                                  desc24.putBoolean( idstyleSheetHasParent, true );
                                  var idfontPostScriptName = stringIDToTypeID( "fontPostScriptName" );
                                  desc24.putString( idfontPostScriptName, """LiberationMono""" );
                                  var idFntN = charIDToTypeID( "FntN" );
                                  desc24.putString( idFntN, """Liberation Mono""" );
                                  var idFntS = charIDToTypeID( "FntS" );
                                  desc24.putString( idFntS, """Regular""" );
                                  var idScrp = charIDToTypeID( "Scrp" );
                                  desc24.putInteger( idScrp, 0 );
                                  var idFntT = charIDToTypeID( "FntT" );
                                  desc24.putInteger( idFntT, 1 );
                                  var idfontAvailable = stringIDToTypeID( "fontAvailable" );
                                  desc24.putBoolean( idfontAvailable, true );
                                  var idSz = charIDToTypeID( "Sz  " );
                                  var idPxl = charIDToTypeID( "#Pxl" );
                                  desc24.putUnitDouble( idSz, idPxl, 116.000000 );
                                  var idimpliedFontSize = stringIDToTypeID( "impliedFontSize" );
                                  var idPxl = charIDToTypeID( "#Pxl" );
                                  desc24.putUnitDouble( idimpliedFontSize, idPxl, 116.000000 );
                                  var iddigitSet = stringIDToTypeID( "digitSet" );
                                  var iddigitSet = stringIDToTypeID( "digitSet" );
                                  var iddefaultDigits = stringIDToTypeID( "defaultDigits" );
                                  desc24.putEnumerated( iddigitSet, iddigitSet, iddefaultDigits );
                                  var idmarkYDistFromBaseline = stringIDToTypeID( "markYDistFromBaseline" );
                                  var idPxl = charIDToTypeID( "#Pxl" );
                                  desc24.putUnitDouble( idmarkYDistFromBaseline, idPxl, 100.000000 );
                                  var idtextLanguage = stringIDToTypeID( "textLanguage" );
                                  var idtextLanguage = stringIDToTypeID( "textLanguage" );
                                  var idenglishLanguage = stringIDToTypeID( "englishLanguage" );
                                  desc24.putEnumerated( idtextLanguage, idtextLanguage, idenglishLanguage );
                                  var idClr = charIDToTypeID( "Clr " );
                                      var desc25 = new ActionDescriptor();
                                      var idRd = charIDToTypeID( "Rd  " );
                                      desc25.putDouble( idRd, 32.879700 );
                                      var idGrn = charIDToTypeID( "Grn " );
                                      desc25.putDouble( idGrn, 37.783352 );
                                      var idBl = charIDToTypeID( "Bl  " );
                                      desc25.putDouble( idBl, 131.001147 );
                                  var idRGBC = charIDToTypeID( "RGBC" );
                                  desc24.putObject( idClr, idRGBC, desc25 );
                                  var idbaseParentStyle = stringIDToTypeID( "baseParentStyle" );
                                      var desc26 = new ActionDescriptor();
                                      var idfontPostScriptName = stringIDToTypeID( "fontPostScriptName" );
                                      desc26.putString( idfontPostScriptName, """MyriadPro-Regular""" );
                                      var idFntN = charIDToTypeID( "FntN" );
                                      desc26.putString( idFntN, """Myriad Pro""" );
                                      var idFntS = charIDToTypeID( "FntS" );
                                      desc26.putString( idFntS, """Regular""" );
                                      var idScrp = charIDToTypeID( "Scrp" );
                                      desc26.putInteger( idScrp, 0 );
                                      var idFntT = charIDToTypeID( "FntT" );
                                      desc26.putInteger( idFntT, 0 );
                                      var idfontAvailable = stringIDToTypeID( "fontAvailable" );
                                      desc26.putBoolean( idfontAvailable, true );
                                      var idSz = charIDToTypeID( "Sz  " );
                                      var idPxl = charIDToTypeID( "#Pxl" );
                                      desc26.putUnitDouble( idSz, idPxl, 12.000000 );
                                      var idimpliedFontSize = stringIDToTypeID( "impliedFontSize" );
                                      var idPxl = charIDToTypeID( "#Pxl" );
                                      desc26.putUnitDouble( idimpliedFontSize, idPxl, 12.000000 );
                                      var idHrzS = charIDToTypeID( "HrzS" );
                                      desc26.putDouble( idHrzS, 100.000000 );
                                      var idVrtS = charIDToTypeID( "VrtS" );
                                      desc26.putDouble( idVrtS, 100.000000 );
                                      var idsyntheticBold = stringIDToTypeID( "syntheticBold" );
                                      desc26.putBoolean( idsyntheticBold, false );
                                      var idsyntheticItalic = stringIDToTypeID( "syntheticItalic" );
                                      desc26.putBoolean( idsyntheticItalic, false );
                                      var idautoLeading = stringIDToTypeID( "autoLeading" );
                                      desc26.putBoolean( idautoLeading, true );
                                      var idTrck = charIDToTypeID( "Trck" );
                                      desc26.putInteger( idTrck, 0 );
                                      var idBsln = charIDToTypeID( "Bsln" );
                                      var idPxl = charIDToTypeID( "#Pxl" );
                                      desc26.putUnitDouble( idBsln, idPxl, 0.000000 );
                                      var idimpliedBaselineShift = stringIDToTypeID( "impliedBaselineShift" );
                                      var idPxl = charIDToTypeID( "#Pxl" );
                                      desc26.putUnitDouble( idimpliedBaselineShift, idPxl, 0.000000 );
                                      var idcharacterRotation = stringIDToTypeID( "characterRotation" );
                                      desc26.putDouble( idcharacterRotation, 0.000000 );
                                      var idAtKr = charIDToTypeID( "AtKr" );
                                      var idAtKr = charIDToTypeID( "AtKr" );
                                      var idmetricsKern = stringIDToTypeID( "metricsKern" );
                                      desc26.putEnumerated( idAtKr, idAtKr, idmetricsKern );
                                      var idfontCaps = stringIDToTypeID( "fontCaps" );
                                      var idfontCaps = stringIDToTypeID( "fontCaps" );
                                      var idNrml = charIDToTypeID( "Nrml" );
                                      desc26.putEnumerated( idfontCaps, idfontCaps, idNrml );
                                      var iddigitSet = stringIDToTypeID( "digitSet" );
                                      var iddigitSet = stringIDToTypeID( "digitSet" );
                                      var iddefaultDigits = stringIDToTypeID( "defaultDigits" );
                                      desc26.putEnumerated( iddigitSet, iddigitSet, iddefaultDigits );
                                      var iddirOverride = stringIDToTypeID( "dirOverride" );
                                      var iddirOverride = stringIDToTypeID( "dirOverride" );
                                      var iddirOverrideDefault = stringIDToTypeID( "dirOverrideDefault" );
                                      desc26.putEnumerated( iddirOverride, iddirOverride, iddirOverrideDefault );
                                      var idkashidas = stringIDToTypeID( "kashidas" );
                                      var idkashidas = stringIDToTypeID( "kashidas" );
                                      var idkashidaDefault = stringIDToTypeID( "kashidaDefault" );
                                      desc26.putEnumerated( idkashidas, idkashidas, idkashidaDefault );
                                      var iddiacVPos = stringIDToTypeID( "diacVPos" );
                                      var iddiacVPos = stringIDToTypeID( "diacVPos" );
                                      var iddiacVPosOpenType = stringIDToTypeID( "diacVPosOpenType" );
                                      desc26.putEnumerated( iddiacVPos, iddiacVPos, iddiacVPosOpenType );
                                      var iddiacXOffset = stringIDToTypeID( "diacXOffset" );
                                      var idPxl = charIDToTypeID( "#Pxl" );
                                      desc26.putUnitDouble( iddiacXOffset, idPxl, 0.000000 );
                                      var iddiacYOffset = stringIDToTypeID( "diacYOffset" );
                                      var idPxl = charIDToTypeID( "#Pxl" );
                                      desc26.putUnitDouble( iddiacYOffset, idPxl, 0.000000 );
                                      var idmarkYDistFromBaseline = stringIDToTypeID( "markYDistFromBaseline" );
                                      var idPxl = charIDToTypeID( "#Pxl" );
                                      desc26.putUnitDouble( idmarkYDistFromBaseline, idPxl, 100.000000 );
                                      var idbaseline = stringIDToTypeID( "baseline" );
                                      var idbaseline = stringIDToTypeID( "baseline" );
                                      var idNrml = charIDToTypeID( "Nrml" );
                                      desc26.putEnumerated( idbaseline, idbaseline, idNrml );
                                      var idotbaseline = stringIDToTypeID( "otbaseline" );
                                      var idotbaseline = stringIDToTypeID( "otbaseline" );
                                      var idNrml = charIDToTypeID( "Nrml" );
                                      desc26.putEnumerated( idotbaseline, idotbaseline, idNrml );
                                      var idstrikethrough = stringIDToTypeID( "strikethrough" );
                                      var idstrikethrough = stringIDToTypeID( "strikethrough" );
                                      var idstrikethroughOff = stringIDToTypeID( "strikethroughOff" );
                                      desc26.putEnumerated( idstrikethrough, idstrikethrough, idstrikethroughOff );
                                      var idUndl = charIDToTypeID( "Undl" );
                                      var idUndl = charIDToTypeID( "Undl" );
                                      var idunderlineOff = stringIDToTypeID( "underlineOff" );
                                      desc26.putEnumerated( idUndl, idUndl, idunderlineOff );
                                      var idunderlineOffset = stringIDToTypeID( "underlineOffset" );
                                      var idPxl = charIDToTypeID( "#Pxl" );
                                      desc26.putUnitDouble( idunderlineOffset, idPxl, 0.000000 );
                                      var idligature = stringIDToTypeID( "ligature" );
                                      desc26.putBoolean( idligature, true );
                                      var idaltligature = stringIDToTypeID( "altligature" );
                                      desc26.putBoolean( idaltligature, false );
                                      var idcontextualLigatures = stringIDToTypeID( "contextualLigatures" );
                                      desc26.putBoolean( idcontextualLigatures, false );
                                      var idalternateLigatures = stringIDToTypeID( "alternateLigatures" );
                                      desc26.putBoolean( idalternateLigatures, false );
                                      var idoldStyle = stringIDToTypeID( "oldStyle" );
                                      desc26.putBoolean( idoldStyle, false );
                                      var idfractions = stringIDToTypeID( "fractions" );
                                      desc26.putBoolean( idfractions, false );
                                      var idordinals = stringIDToTypeID( "ordinals" );
                                      desc26.putBoolean( idordinals, false );
                                      var idswash = stringIDToTypeID( "swash" );
                                      desc26.putBoolean( idswash, false );
                                      var idtitling = stringIDToTypeID( "titling" );
                                      desc26.putBoolean( idtitling, false );
                                      var idconnectionForms = stringIDToTypeID( "connectionForms" );
                                      desc26.putBoolean( idconnectionForms, false );
                                      var idstylisticAlternates = stringIDToTypeID( "stylisticAlternates" );
                                      desc26.putBoolean( idstylisticAlternates, false );
                                      var idornaments = stringIDToTypeID( "ornaments" );
                                      desc26.putBoolean( idornaments, false );
                                      var idjustificationAlternates = stringIDToTypeID( "justificationAlternates" );
                                      desc26.putBoolean( idjustificationAlternates, false );
                                      var idfigureStyle = stringIDToTypeID( "figureStyle" );
                                      var idfigureStyle = stringIDToTypeID( "figureStyle" );
                                      var idNrml = charIDToTypeID( "Nrml" );
                                      desc26.putEnumerated( idfigureStyle, idfigureStyle, idNrml );
                                      var idproportionalMetrics = stringIDToTypeID( "proportionalMetrics" );
                                      desc26.putBoolean( idproportionalMetrics, false );
                                      var idkana = stringIDToTypeID( "kana" );
                                      desc26.putBoolean( idkana, false );
                                      var iditalics = stringIDToTypeID( "italics" );
                                      desc26.putBoolean( iditalics, false );
                                      var idruby = stringIDToTypeID( "ruby" );
                                      desc26.putBoolean( idruby, false );
                                      var idbaselineDirection = stringIDToTypeID( "baselineDirection" );
                                      var idbaselineDirection = stringIDToTypeID( "baselineDirection" );
                                      var idrotated = stringIDToTypeID( "rotated" );
                                      desc26.putEnumerated( idbaselineDirection, idbaselineDirection, idrotated );
                                      var idtextLanguage = stringIDToTypeID( "textLanguage" );
                                      var idtextLanguage = stringIDToTypeID( "textLanguage" );
                                      var idenglishLanguage = stringIDToTypeID( "englishLanguage" );
                                      desc26.putEnumerated( idtextLanguage, idtextLanguage, idenglishLanguage );
                                      var idjapaneseAlternate = stringIDToTypeID( "japaneseAlternate" );
                                      var idjapaneseAlternate = stringIDToTypeID( "japaneseAlternate" );
                                      var iddefaultForm = stringIDToTypeID( "defaultForm" );
                                      desc26.putEnumerated( idjapaneseAlternate, idjapaneseAlternate, iddefaultForm );
                                      var idmojiZume = stringIDToTypeID( "mojiZume" );
                                      desc26.putDouble( idmojiZume, 0.000000 );
                                      var idgridAlignment = stringIDToTypeID( "gridAlignment" );
                                      var idgridAlignment = stringIDToTypeID( "gridAlignment" );
                                      var idroman = stringIDToTypeID( "roman" );
                                      desc26.putEnumerated( idgridAlignment, idgridAlignment, idroman );
                                      var idenableWariChu = stringIDToTypeID( "enableWariChu" );
                                      desc26.putBoolean( idenableWariChu, false );
                                      var idwariChuCount = stringIDToTypeID( "wariChuCount" );
                                      desc26.putInteger( idwariChuCount, 2 );
                                      var idwariChuLineGap = stringIDToTypeID( "wariChuLineGap" );
                                      desc26.putInteger( idwariChuLineGap, 0 );
                                      var idwariChuScale = stringIDToTypeID( "wariChuScale" );
                                      desc26.putDouble( idwariChuScale, 0.500000 );
                                      var idwariChuWidow = stringIDToTypeID( "wariChuWidow" );
                                      desc26.putInteger( idwariChuWidow, 2 );
                                      var idwariChuOrphan = stringIDToTypeID( "wariChuOrphan" );
                                      desc26.putInteger( idwariChuOrphan, 2 );
                                      var idwariChuJustification = stringIDToTypeID( "wariChuJustification" );
                                      var idwariChuJustification = stringIDToTypeID( "wariChuJustification" );
                                      var idwariChuAutoJustify = stringIDToTypeID( "wariChuAutoJustify" );
                                      desc26.putEnumerated( idwariChuJustification, idwariChuJustification, idwariChuAutoJustify );
                                      var idtcyUpDown = stringIDToTypeID( "tcyUpDown" );
                                      desc26.putInteger( idtcyUpDown, 0 );
                                      var idtcyLeftRight = stringIDToTypeID( "tcyLeftRight" );
                                      desc26.putInteger( idtcyLeftRight, 0 );
                                      var idleftAki = stringIDToTypeID( "leftAki" );
                                      desc26.putDouble( idleftAki, -1.000000 );
                                      var idrightAki = stringIDToTypeID( "rightAki" );
                                      desc26.putDouble( idrightAki, -1.000000 );
                                      var idjiDori = stringIDToTypeID( "jiDori" );
                                      desc26.putInteger( idjiDori, 0 );
                                      var idnoBreak = stringIDToTypeID( "noBreak" );
                                      desc26.putBoolean( idnoBreak, false );
                                      var idClr = charIDToTypeID( "Clr " );
                                          var desc27 = new ActionDescriptor();
                                          var idRd = charIDToTypeID( "Rd  " );
                                          desc27.putDouble( idRd, 0.000000 );
                                          var idGrn = charIDToTypeID( "Grn " );
                                          desc27.putDouble( idGrn, 0.000000 );
                                          var idBl = charIDToTypeID( "Bl  " );
                                          desc27.putDouble( idBl, 0.000000 );
                                      var idRGBC = charIDToTypeID( "RGBC" );
                                      desc26.putObject( idClr, idRGBC, desc27 );
                                      var idstrokeColor = stringIDToTypeID( "strokeColor" );
                                          var desc28 = new ActionDescriptor();
                                          var idRd = charIDToTypeID( "Rd  " );
                                          desc28.putDouble( idRd, 0.000000 );
                                          var idGrn = charIDToTypeID( "Grn " );
                                          desc28.putDouble( idGrn, 0.000000 );
                                          var idBl = charIDToTypeID( "Bl  " );
                                          desc28.putDouble( idBl, 0.000000 );
                                      var idRGBC = charIDToTypeID( "RGBC" );
                                      desc26.putObject( idstrokeColor, idRGBC, desc28 );
                                      var idFl = charIDToTypeID( "Fl  " );
                                      desc26.putBoolean( idFl, true );
                                      var idStrk = charIDToTypeID( "Strk" );
                                      desc26.putBoolean( idStrk, false );
                                      var idfillFirst = stringIDToTypeID( "fillFirst" );
                                      desc26.putBoolean( idfillFirst, true );
                                      var idfillOverPrint = stringIDToTypeID( "fillOverPrint" );
                                      desc26.putBoolean( idfillOverPrint, false );
                                      var idstrokeOverPrint = stringIDToTypeID( "strokeOverPrint" );
                                      desc26.putBoolean( idstrokeOverPrint, false );
                                      var idlineCap = stringIDToTypeID( "lineCap" );
                                      var idlineCap = stringIDToTypeID( "lineCap" );
                                      var idbuttCap = stringIDToTypeID( "buttCap" );
                                      desc26.putEnumerated( idlineCap, idlineCap, idbuttCap );
                                      var idlineJoin = stringIDToTypeID( "lineJoin" );
                                      var idlineJoin = stringIDToTypeID( "lineJoin" );
                                      var idmiterJoin = stringIDToTypeID( "miterJoin" );
                                      desc26.putEnumerated( idlineJoin, idlineJoin, idmiterJoin );
                                      var idlineWidth = stringIDToTypeID( "lineWidth" );
                                      var idPxl = charIDToTypeID( "#Pxl" );
                                      desc26.putUnitDouble( idlineWidth, idPxl, 1.000000 );
                                      var idmiterLimit = stringIDToTypeID( "miterLimit" );
                                      var idPxl = charIDToTypeID( "#Pxl" );
                                      desc26.putUnitDouble( idmiterLimit, idPxl, 4.000000 );
                                      var idlineDashoffset = stringIDToTypeID( "lineDashoffset" );
                                      desc26.putDouble( idlineDashoffset, 0.000000 );
                                  var idTxtS = charIDToTypeID( "TxtS" );
                                  desc24.putObject( idbaseParentStyle, idTxtS, desc26 );
                              var idTxtS = charIDToTypeID( "TxtS" );
                              desc23.putObject( idTxtS, idTxtS, desc24 );
                          var idTxtt = charIDToTypeID( "Txtt" );
                          list2.putObject( idTxtt, desc23 );
                      desc15.putList( idTxtt, list2 );
                      var idparagraphStyleRange = stringIDToTypeID( "paragraphStyleRange" );
                          var list3 = new ActionList();
                              var desc29 = new ActionDescriptor();
                              var idFrom = charIDToTypeID( "From" );
                              desc29.putInteger( idFrom, 0 );
                              var idT = charIDToTypeID( "T   " );
                              desc29.putInteger( idT, 5 );
                              var idparagraphStyle = stringIDToTypeID( "paragraphStyle" );
                                  var desc30 = new ActionDescriptor();
                                  var idstyleSheetHasParent = stringIDToTypeID( "styleSheetHasParent" );
                                  desc30.putBoolean( idstyleSheetHasParent, true );
                                  var idAlgn = charIDToTypeID( "Algn" );
                                  var idAlg = charIDToTypeID( "Alg " );
                                  var idLeft = charIDToTypeID( "Left" );
                                  desc30.putEnumerated( idAlgn, idAlg, idLeft );
                                  var idfirstLineIndent = stringIDToTypeID( "firstLineIndent" );
                                  var idPxl = charIDToTypeID( "#Pxl" );
                                  desc30.putUnitDouble( idfirstLineIndent, idPxl, 0.000000 );
                                  var idimpliedFirstLineIndent = stringIDToTypeID( "impliedFirstLineIndent" );
                                  var idPxl = charIDToTypeID( "#Pxl" );
                                  desc30.putUnitDouble( idimpliedFirstLineIndent, idPxl, 0.000000 );
                                  var idstartIndent = stringIDToTypeID( "startIndent" );
                                  var idPxl = charIDToTypeID( "#Pxl" );
                                  desc30.putUnitDouble( idstartIndent, idPxl, 0.000000 );
                                  var idimpliedStartIndent = stringIDToTypeID( "impliedStartIndent" );
                                  var idPxl = charIDToTypeID( "#Pxl" );
                                  desc30.putUnitDouble( idimpliedStartIndent, idPxl, 0.000000 );
                                  var idendIndent = stringIDToTypeID( "endIndent" );
                                  var idPxl = charIDToTypeID( "#Pxl" );
                                  desc30.putUnitDouble( idendIndent, idPxl, 0.000000 );
                                  var idimpliedEndIndent = stringIDToTypeID( "impliedEndIndent" );
                                  var idPxl = charIDToTypeID( "#Pxl" );
                                  desc30.putUnitDouble( idimpliedEndIndent, idPxl, 0.000000 );
                                  var idspaceBefore = stringIDToTypeID( "spaceBefore" );
                                  var idPxl = charIDToTypeID( "#Pxl" );
                                  desc30.putUnitDouble( idspaceBefore, idPxl, 0.000000 );
                                  var idimpliedSpaceBefore = stringIDToTypeID( "impliedSpaceBefore" );
                                  var idPxl = charIDToTypeID( "#Pxl" );
                                  desc30.putUnitDouble( idimpliedSpaceBefore, idPxl, 0.000000 );
                                  var idspaceAfter = stringIDToTypeID( "spaceAfter" );
                                  var idPxl = charIDToTypeID( "#Pxl" );
                                  desc30.putUnitDouble( idspaceAfter, idPxl, 0.000000 );
                                  var idimpliedSpaceAfter = stringIDToTypeID( "impliedSpaceAfter" );
                                  var idPxl = charIDToTypeID( "#Pxl" );
                                  desc30.putUnitDouble( idimpliedSpaceAfter, idPxl, 0.000000 );
                                  var iddropCapMultiplier = stringIDToTypeID( "dropCapMultiplier" );
                                  desc30.putInteger( iddropCapMultiplier, 1 );
                                  var idautoLeadingPercentage = stringIDToTypeID( "autoLeadingPercentage" );
                                  desc30.putDouble( idautoLeadingPercentage, 1.200000 );
                                  var idleadingType = stringIDToTypeID( "leadingType" );
                                  var idleadingType = stringIDToTypeID( "leadingType" );
                                  var idleadingBelow = stringIDToTypeID( "leadingBelow" );
                                  desc30.putEnumerated( idleadingType, idleadingType, idleadingBelow );
                                  var iddirectionType = stringIDToTypeID( "directionType" );
                                  var iddirectionType = stringIDToTypeID( "directionType" );
                                  var iddirLeftToRight = stringIDToTypeID( "dirLeftToRight" );
                                  desc30.putEnumerated( iddirectionType, iddirectionType, iddirLeftToRight );
                                  var idkashidaWidthType = stringIDToTypeID( "kashidaWidthType" );
                                  var idkashidaWidthType = stringIDToTypeID( "kashidaWidthType" );
                                  var idkashidaWidthMedium = stringIDToTypeID( "kashidaWidthMedium" );
                                  desc30.putEnumerated( idkashidaWidthType, idkashidaWidthType, idkashidaWidthMedium );
                                  var idjustificationMethodType = stringIDToTypeID( "justificationMethodType" );
                                  var idjustificationMethodType = stringIDToTypeID( "justificationMethodType" );
                                  var idjustifMethodAutomatic = stringIDToTypeID( "justifMethodAutomatic" );
                                  desc30.putEnumerated( idjustificationMethodType, idjustificationMethodType, idjustifMethodAutomatic );
                                  var idhyphenate = stringIDToTypeID( "hyphenate" );
                                  desc30.putBoolean( idhyphenate, false );
                                  var idhyphenateWordSize = stringIDToTypeID( "hyphenateWordSize" );
                                  desc30.putInteger( idhyphenateWordSize, 6 );
                                  var idhyphenatePreLength = stringIDToTypeID( "hyphenatePreLength" );
                                  desc30.putInteger( idhyphenatePreLength, 2 );
                                  var idhyphenatePostLength = stringIDToTypeID( "hyphenatePostLength" );
                                  desc30.putInteger( idhyphenatePostLength, 2 );
                                  var idhyphenateLimit = stringIDToTypeID( "hyphenateLimit" );
                                  desc30.putInteger( idhyphenateLimit, 0 );
                                  var idhyphenationZone = stringIDToTypeID( "hyphenationZone" );
                                  desc30.putDouble( idhyphenationZone, 36.000000 );
                                  var idhyphenateCapitalized = stringIDToTypeID( "hyphenateCapitalized" );
                                  desc30.putBoolean( idhyphenateCapitalized, true );
                                  var idhyphenationPreference = stringIDToTypeID( "hyphenationPreference" );
                                  desc30.putDouble( idhyphenationPreference, 0.500000 );
                                  var idjustificationWordMinimum = stringIDToTypeID( "justificationWordMinimum" );
                                  desc30.putDouble( idjustificationWordMinimum, 0.800000 );
                                  var idjustificationWordDesired = stringIDToTypeID( "justificationWordDesired" );
                                  desc30.putDouble( idjustificationWordDesired, 1.000000 );
                                  var idjustificationWordMaximum = stringIDToTypeID( "justificationWordMaximum" );
                                  desc30.putDouble( idjustificationWordMaximum, 1.330000 );
                                  var idjustificationLetterMinimum = stringIDToTypeID( "justificationLetterMinimum" );
                                  desc30.putDouble( idjustificationLetterMinimum, 0.000000 );
                                  var idjustificationLetterDesired = stringIDToTypeID( "justificationLetterDesired" );
                                  desc30.putDouble( idjustificationLetterDesired, 0.000000 );
                                  var idjustificationLetterMaximum = stringIDToTypeID( "justificationLetterMaximum" );
                                  desc30.putDouble( idjustificationLetterMaximum, 0.000000 );
                                  var idjustificationGlyphMinimum = stringIDToTypeID( "justificationGlyphMinimum" );
                                  desc30.putDouble( idjustificationGlyphMinimum, 1.000000 );
                                  var idjustificationGlyphDesired = stringIDToTypeID( "justificationGlyphDesired" );
                                  desc30.putDouble( idjustificationGlyphDesired, 1.000000 );
                                  var idjustificationGlyphMaximum = stringIDToTypeID( "justificationGlyphMaximum" );
                                  desc30.putDouble( idjustificationGlyphMaximum, 1.000000 );
                                  var idsingleWordJustification = stringIDToTypeID( "singleWordJustification" );
                                  var idAlg = charIDToTypeID( "Alg " );
                                  var idJstA = charIDToTypeID( "JstA" );
                                  desc30.putEnumerated( idsingleWordJustification, idAlg, idJstA );
                                  var idhangingRoman = stringIDToTypeID( "hangingRoman" );
                                  desc30.putBoolean( idhangingRoman, false );
                                  var idautoTCY = stringIDToTypeID( "autoTCY" );
                                  desc30.putInteger( idautoTCY, 0 );
                                  var idkeepTogether = stringIDToTypeID( "keepTogether" );
                                  desc30.putBoolean( idkeepTogether, true );
                                  var idburasagari = stringIDToTypeID( "burasagari" );
                                  var idburasagari = stringIDToTypeID( "burasagari" );
                                  var idburasagariNone = stringIDToTypeID( "burasagariNone" );
                                  desc30.putEnumerated( idburasagari, idburasagari, idburasagariNone );
                                  var idpreferredKinsokuOrder = stringIDToTypeID( "preferredKinsokuOrder" );
                                  var idpreferredKinsokuOrder = stringIDToTypeID( "preferredKinsokuOrder" );
                                  var idpushIn = stringIDToTypeID( "pushIn" );
                                  desc30.putEnumerated( idpreferredKinsokuOrder, idpreferredKinsokuOrder, idpushIn );
                                  var idkurikaeshiMojiShori = stringIDToTypeID( "kurikaeshiMojiShori" );
                                  desc30.putBoolean( idkurikaeshiMojiShori, false );
                                  var idtextEveryLineComposer = stringIDToTypeID( "textEveryLineComposer" );
                                  desc30.putBoolean( idtextEveryLineComposer, false );
                                  var iddefaultTabWidth = stringIDToTypeID( "defaultTabWidth" );
                                  desc30.putDouble( iddefaultTabWidth, 36.000000 );
                                  var iddefaultStyle = stringIDToTypeID( "defaultStyle" );
                                      var desc31 = new ActionDescriptor();
                                      var idfontPostScriptName = stringIDToTypeID( "fontPostScriptName" );
                                      desc31.putString( idfontPostScriptName, """MyriadPro-Regular""" );
                                      var idFntN = charIDToTypeID( "FntN" );
                                      desc31.putString( idFntN, """Myriad Pro""" );
                                      var idFntS = charIDToTypeID( "FntS" );
                                      desc31.putString( idFntS, """Regular""" );
                                      var idScrp = charIDToTypeID( "Scrp" );
                                      desc31.putInteger( idScrp, 0 );
                                      var idFntT = charIDToTypeID( "FntT" );
                                      desc31.putInteger( idFntT, 0 );
                                      var idfontAvailable = stringIDToTypeID( "fontAvailable" );
                                      desc31.putBoolean( idfontAvailable, true );
                                      var idSz = charIDToTypeID( "Sz  " );
                                      var idPxl = charIDToTypeID( "#Pxl" );
                                      desc31.putUnitDouble( idSz, idPxl, 12.000000 );
                                      var idHrzS = charIDToTypeID( "HrzS" );
                                      desc31.putDouble( idHrzS, 100.000000 );
                                      var idVrtS = charIDToTypeID( "VrtS" );
                                      desc31.putDouble( idVrtS, 100.000000 );
                                      var idsyntheticBold = stringIDToTypeID( "syntheticBold" );
                                      desc31.putBoolean( idsyntheticBold, false );
                                      var idsyntheticItalic = stringIDToTypeID( "syntheticItalic" );
                                      desc31.putBoolean( idsyntheticItalic, false );
                                      var idautoLeading = stringIDToTypeID( "autoLeading" );
                                      desc31.putBoolean( idautoLeading, true );
                                      var idTrck = charIDToTypeID( "Trck" );
                                      desc31.putInteger( idTrck, 0 );
                                      var idBsln = charIDToTypeID( "Bsln" );
                                      var idPxl = charIDToTypeID( "#Pxl" );
                                      desc31.putUnitDouble( idBsln, idPxl, 0.000000 );
                                      var idcharacterRotation = stringIDToTypeID( "characterRotation" );
                                      desc31.putDouble( idcharacterRotation, 0.000000 );
                                      var idAtKr = charIDToTypeID( "AtKr" );
                                      var idAtKr = charIDToTypeID( "AtKr" );
                                      var idmetricsKern = stringIDToTypeID( "metricsKern" );
                                      desc31.putEnumerated( idAtKr, idAtKr, idmetricsKern );
                                      var idfontCaps = stringIDToTypeID( "fontCaps" );
                                      var idfontCaps = stringIDToTypeID( "fontCaps" );
                                      var idNrml = charIDToTypeID( "Nrml" );
                                      desc31.putEnumerated( idfontCaps, idfontCaps, idNrml );
                                      var iddigitSet = stringIDToTypeID( "digitSet" );
                                      var iddigitSet = stringIDToTypeID( "digitSet" );
                                      var idarabicDigits = stringIDToTypeID( "arabicDigits" );
                                      desc31.putEnumerated( iddigitSet, iddigitSet, idarabicDigits );
                                      var idkashidas = stringIDToTypeID( "kashidas" );
                                      var idkashidas = stringIDToTypeID( "kashidas" );
                                      var idkashidaDefault = stringIDToTypeID( "kashidaDefault" );
                                      desc31.putEnumerated( idkashidas, idkashidas, idkashidaDefault );
                                      var iddiacVPos = stringIDToTypeID( "diacVPos" );
                                      var iddiacVPos = stringIDToTypeID( "diacVPos" );
                                      var iddiacVPosOpenType = stringIDToTypeID( "diacVPosOpenType" );
                                      desc31.putEnumerated( iddiacVPos, iddiacVPos, iddiacVPosOpenType );
                                      var iddiacXOffset = stringIDToTypeID( "diacXOffset" );
                                      var idPxl = charIDToTypeID( "#Pxl" );
                                      desc31.putUnitDouble( iddiacXOffset, idPxl, 0.000000 );
                                      var iddiacYOffset = stringIDToTypeID( "diacYOffset" );
                                      var idPxl = charIDToTypeID( "#Pxl" );
                                      desc31.putUnitDouble( iddiacYOffset, idPxl, 0.000000 );
                                      var idmarkYDistFromBaseline = stringIDToTypeID( "markYDistFromBaseline" );
                                      var idPxl = charIDToTypeID( "#Pxl" );
                                      desc31.putUnitDouble( idmarkYDistFromBaseline, idPxl, 0.000000 );
                                      var idbaseline = stringIDToTypeID( "baseline" );
                                      var idbaseline = stringIDToTypeID( "baseline" );
                                      var idNrml = charIDToTypeID( "Nrml" );
                                      desc31.putEnumerated( idbaseline, idbaseline, idNrml );
                                      var idstrikethrough = stringIDToTypeID( "strikethrough" );
                                      var idstrikethrough = stringIDToTypeID( "strikethrough" );
                                      var idstrikethroughOff = stringIDToTypeID( "strikethroughOff" );
                                      desc31.putEnumerated( idstrikethrough, idstrikethrough, idstrikethroughOff );
                                      var idUndl = charIDToTypeID( "Undl" );
                                      var idUndl = charIDToTypeID( "Undl" );
                                      var idunderlineOff = stringIDToTypeID( "underlineOff" );
                                      desc31.putEnumerated( idUndl, idUndl, idunderlineOff );
                                      var idligature = stringIDToTypeID( "ligature" );
                                      desc31.putBoolean( idligature, true );
                                      var idaltligature = stringIDToTypeID( "altligature" );
                                      desc31.putBoolean( idaltligature, false );
                                      var idcontextualLigatures = stringIDToTypeID( "contextualLigatures" );
                                      desc31.putBoolean( idcontextualLigatures, true );
                                      var idalternateLigatures = stringIDToTypeID( "alternateLigatures" );
                                      desc31.putBoolean( idalternateLigatures, false );
                                      var idoldStyle = stringIDToTypeID( "oldStyle" );
                                      desc31.putBoolean( idoldStyle, false );
                                      var idfractions = stringIDToTypeID( "fractions" );
                                      desc31.putBoolean( idfractions, false );
                                      var idordinals = stringIDToTypeID( "ordinals" );
                                      desc31.putBoolean( idordinals, false );
                                      var idswash = stringIDToTypeID( "swash" );
                                      desc31.putBoolean( idswash, false );
                                      var idtitling = stringIDToTypeID( "titling" );
                                      desc31.putBoolean( idtitling, false );
                                      var idconnectionForms = stringIDToTypeID( "connectionForms" );
                                      desc31.putBoolean( idconnectionForms, false );
                                      var idstylisticAlternates = stringIDToTypeID( "stylisticAlternates" );
                                      desc31.putBoolean( idstylisticAlternates, false );
                                      var idornaments = stringIDToTypeID( "ornaments" );
                                      desc31.putBoolean( idornaments, false );
                                      var idfigureStyle = stringIDToTypeID( "figureStyle" );
                                      var idfigureStyle = stringIDToTypeID( "figureStyle" );
                                      var idNrml = charIDToTypeID( "Nrml" );
                                      desc31.putEnumerated( idfigureStyle, idfigureStyle, idNrml );
                                      var idbaselineDirection = stringIDToTypeID( "baselineDirection" );
                                      var idbaselineDirection = stringIDToTypeID( "baselineDirection" );
                                      var idwithStream = stringIDToTypeID( "withStream" );
                                      desc31.putEnumerated( idbaselineDirection, idbaselineDirection, idwithStream );
                                      var idtextLanguage = stringIDToTypeID( "textLanguage" );
                                      var idtextLanguage = stringIDToTypeID( "textLanguage" );
                                      var idukenglishLanguage = stringIDToTypeID( "ukenglishLanguage" );
                                      desc31.putEnumerated( idtextLanguage, idtextLanguage, idukenglishLanguage );
                                      var idClr = charIDToTypeID( "Clr " );
                                          var desc32 = new ActionDescriptor();
                                          var idRd = charIDToTypeID( "Rd  " );
                                          desc32.putDouble( idRd, 0.000000 );
                                          var idGrn = charIDToTypeID( "Grn " );
                                          desc32.putDouble( idGrn, 0.000000 );
                                          var idBl = charIDToTypeID( "Bl  " );
                                          desc32.putDouble( idBl, 0.000000 );
                                      var idRGBC = charIDToTypeID( "RGBC" );
                                      desc31.putObject( idClr, idRGBC, desc32 );
                                      var idstrokeColor = stringIDToTypeID( "strokeColor" );
                                          var desc33 = new ActionDescriptor();
                                          var idRd = charIDToTypeID( "Rd  " );
                                          desc33.putDouble( idRd, 0.000000 );
                                          var idGrn = charIDToTypeID( "Grn " );
                                          desc33.putDouble( idGrn, 0.000000 );
                                          var idBl = charIDToTypeID( "Bl  " );
                                          desc33.putDouble( idBl, 0.000000 );
                                      var idRGBC = charIDToTypeID( "RGBC" );
                                      desc31.putObject( idstrokeColor, idRGBC, desc33 );
                                  var idTxtS = charIDToTypeID( "TxtS" );
                                  desc30.putObject( iddefaultStyle, idTxtS, desc31 );
                              var idparagraphStyle = stringIDToTypeID( "paragraphStyle" );
                              desc29.putObject( idparagraphStyle, idparagraphStyle, desc30 );
                          var idparagraphStyleRange = stringIDToTypeID( "paragraphStyleRange" );
                          list3.putObject( idparagraphStyleRange, desc29 );
                      desc15.putList( idparagraphStyleRange, list3 );
                      var idkerningRange = stringIDToTypeID( "kerningRange" );
                          var list4 = new ActionList();
                      desc15.putList( idkerningRange, list4 );
                  var idTxLr = charIDToTypeID( "TxLr" );
                  desc14.putObject( idUsng, idTxLr, desc15 );
                  var idLyrI = charIDToTypeID( "LyrI" );
                  desc14.putInteger( idLyrI, 2 );
              executeAction( idMk, desc14, DialogModes.NO );