brew Posted November 5, 2008 Share Posted November 5, 2008 I have data that sometimes has the registered symbol in it (the circle with the R in it). This looks correct in the data (it's a smaller symbol and automatically superscripted). My problem, is that when I use that field as a variable, the registered symbol is always way too big and never superscripted. Is there any easier way to get this to look "correct" other than writing alot of rules for each field that could have one of these symbols and doing a z newsize and a superscript tag around a 174 entity and doing a ReplaceSubstring? And, if this is the only method available, what happens when I have my text box "adjust text to fit?" Will it also decrease the font size of the hardcoded z newsize that I did for the registered mark? Thanks. Link to comment Share on other sites More sharing options...
Dan Korn Posted November 5, 2008 Share Posted November 5, 2008 I have data that sometimes has the registered symbol in it (the circle with the R in it). This looks correct in the data (it's a smaller symbol and automatically superscripted). I have to take issue with what you're saying here. Technically, what's in the data is just a number which represents a character (code point). It's all just zeros and ones. It doesn't "look like" anything, until you open it in some kind of text viewer or editing application, which displays it in a particular font. What you're looking at is a glyph in a particular font which is a representation of that code point, but it's not the actual "data." So saying that it "looks correct in the data" is meaningless. My problem, is that when I use that field as a variable, the registered symbol is always way too big and never superscripted. Again, what you're looking at depends, almost entirely, on the particular font in which you're rendering the text. You're looking at a glyph which represents the character. So, if the data "looks correct" in whatever application you're using to view the contents of your input file, then what I would do is figure out what font that application is using to display the data, and use that same font in your composition. Is there any easier way to get this to look "correct" other than writing alot of rules for each field that could have one of these symbols and doing a z newsize and a superscript tag around a 174 entity and doing a ReplaceSubstring? Like I said, put it in whatever font it "looks correct" in with the other application. And, if this is the only method available, what happens when I have my text box "adjust text to fit?" Will it also decrease the font size of the hardcoded z newsize that I did for the registered mark? Yes. Copyfitting uses <magnify> tags to adjust the text, so every bit of the text is adjusted, within the specified parameters of the MagnifyAttributes object in your OnCopyfit rule. Remember that all text that you type into the text editor is "hard coded" in a particular point size. You can see this if you look in the DIF file; it's using the same <z newsize> tags there. The copyfitting logic simply applies <magnify> tags which adjust the point size and other attributes of the text, with the "hard coded" attributes in the tagged markup as a starting point to which the magnification is applied. Link to comment Share on other sites More sharing options...
DSweet Posted November 6, 2008 Share Posted November 6, 2008 Brew, Instead of writing a number of rules to accomodate this, you could try a function. Then you would only have one substitution rule to create, and you would just pass individual strings to it. Good luck, Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.