Quantcast
Channel: Adobe Community : Popular Discussions - Adobe FrameMaker
Viewing all articles
Browse latest Browse all 23442

applying fcode to a text range?

$
0
0

Hi all,

 

I'm trying to apply an fcode to a text range.

 

If I manually select text, this code makes the text bold:

fcodes = new Array();

fcodes[0] = FCodes.TXT_BOLD;

Fcodes(fcodes);

 

However, if I try to programmatically select the text, the fcode has no effect:

var tr = new TextRange (); 

tr.beg.obj = tr.end.obj = pgf; 

tr.beg.offset = 0; 

tr.end.offset = 5;

fcodes = new Array();

fcodes[0] = FCodes.TXT_BOLD;

Fcodes(fcodes);

 

I fear I'm missing something simple or obvious. Must my code explicitly toggle the text range as "selected"?

 

-Alan


Viewing all articles
Browse latest Browse all 23442

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>