xref class as print-only?
xref class as print-only?
Is it possible to flag a custom xref class as "print only"?
Here's the situation:
I don't care for the usual cross reference scheme, because I often want to have the jump follow text of my own selection. For example, the jump label may be singular, because it makes grammatic sense to what I'm trying to say, but the section heading it points to is plural. I don't want to repeat that character for character, I just want to have a working jump to it.
So, rather than go with cross references, I used hyperlinks. This allows me to show whatever text I want as the link caption.
But now I'm thinking ahead to print output. I don't see an option to format the hyperlink print style to show a page number; that seems to be confined to cross references. So, I thought, I'll create a cross-reference class just for the purpose of the print job, so I can show the page number.
But I can't find a way to have that as print-only. I tried deleting all of the coding associated with the non-print style, but that was not allowed. I tried setting the length to 0 for the default medium, and default for the print medium, but the page number ended up showing in the webhelp anyway.
1. Is there a way to show a page number for a hyperlink?
2. If not, is there a way to flag a cross reference style as print-only?
Here's the situation:
I don't care for the usual cross reference scheme, because I often want to have the jump follow text of my own selection. For example, the jump label may be singular, because it makes grammatic sense to what I'm trying to say, but the section heading it points to is plural. I don't want to repeat that character for character, I just want to have a working jump to it.
So, rather than go with cross references, I used hyperlinks. This allows me to show whatever text I want as the link caption.
But now I'm thinking ahead to print output. I don't see an option to format the hyperlink print style to show a page number; that seems to be confined to cross references. So, I thought, I'll create a cross-reference class just for the purpose of the print job, so I can show the page number.
But I can't find a way to have that as print-only. I tried deleting all of the coding associated with the non-print style, but that was not allowed. I tried setting the length to 0 for the default medium, and default for the print medium, but the page number ended up showing in the webhelp anyway.
1. Is there a way to show a page number for a hyperlink?
2. If not, is there a way to flag a cross reference style as print-only?
Judy Hennessey
Re: xref class as print-only?
You might be able to use the "display" property of your cross-reference class to hide it in screen output - set the property to "none" for your default medium and to (I think) "inherit" or "block" for your print medium.
Re: xref class as print-only?
One problem with this method is that any hidden xrefs could be revealed by a search - i.e. if you searched for a term in the xref and displayed the topic, the hidden xref would be displayed.crdunn wrote:You might be able to use the "display" property of your cross-reference class to hide it in screen output - set the property to "none" for your default medium and to (I think) "inherit" or "block" for your print medium.
I don't think you can get what you want just by using hyperlinks or xrefs throughout - you can only enter your own link text if you use hyperlinks, and you can only have page numbering if you use xrefs.
The only way I can see to do this is to enter both a hyperlink and xref and use print/screen conditional tags. Obviously you'd only need to do this in cases where the link text needs to be different to what is displayed by using a xref format.
Re: xref class as print-only?
Which brings us back to
2. If not, is there a way to flag a cross reference style as print-only?
I haven't been able to find a property of the xref class to allow me to set a condition tag on all references. Would I have to select each cross reference as text, then apply the print-only condition individually?
2. If not, is there a way to flag a cross reference style as print-only?
I haven't been able to find a property of the xref class to allow me to set a condition tag on all references. Would I have to select each cross reference as text, then apply the print-only condition individually?
Judy Hennessey
Re: xref class as print-only?
No, you can't use conditional tags to exclude content that uses a particular style, you'd need to apply the conditional tag to the hyperlink/xref.JudyH wrote:Which brings us back to
2. If not, is there a way to flag a cross reference style as print-only?
I haven't been able tro find a property of the xref class to allow me to set a condition tag on all references. Would I have to select each cross reference as text, then apply the print-only condition individually?
Re: xref class as print-only?
I believe someone else has put in a request for similar functionality (being able to apply a conditional tag to a style). Make sure you submit a request, too. The more who request something and all that... Submit your request at http://www.madcapsoftware.com/bugs/submit.aspx.
Lisa
Eagles may soar, but weasels aren't sucked into jet engines.
Warning! Loose nut behind the keyboard.
-
- Sr. Propeller Head
- Posts: 342
- Joined: Mon Nov 03, 2008 9:33 am
- Location: The heart of America
Re: xref class as print-only?
On the topic of cross referencing...
I have screen captions with captions under them. Each caption has an autonumber and a bookmark. Within the body of the document, I have the xref set to {paranumonly} so it will only show the caption figure number.
It works within the text editor just fine, but in preview and build, it is missing completely. Is there somewhere I need to assign a label besides just telling it to only show the figure number?
Thanks,
Andrea
I have screen captions with captions under them. Each caption has an autonumber and a bookmark. Within the body of the document, I have the xref set to {paranumonly} so it will only show the caption figure number.
It works within the text editor just fine, but in preview and build, it is missing completely. Is there somewhere I need to assign a label besides just telling it to only show the figure number?
Thanks,
Andrea
The Moon is the first milestone on the road to the stars.
— Arthur C. Clarke
— Arthur C. Clarke
Re: xref class as print-only?
Are you building print or online output?
Lisa
Eagles may soar, but weasels aren't sucked into jet engines.
Warning! Loose nut behind the keyboard.
-
- Sr. Propeller Head
- Posts: 342
- Joined: Mon Nov 03, 2008 9:33 am
- Location: The heart of America
Re: xref class as print-only?
I only have it set up for PDF print version. I am wondering if there is a label somewhere that is not set up because everything else seems to work. If I set the mc-format to 'See {paranumonly}' then in my print preview mode it will say "See " and then not list the figure. Everything works exactly in the editor.
The Moon is the first milestone on the road to the stars.
— Arthur C. Clarke
— Arthur C. Clarke
Re: xref class as print-only?
It works for me, but I use a global counter on my figures, not chapter-wide. I'm not sure if that makes a difference. In the preview it will always display as "see Figure 1" but in the final PDF output, it will resolve to "see Figure 20" or whatever. And it works across chapters. For instance, I have a sentence that comes out as "Figure 102 is a more detailed version of Figure 1 on page 13". So "Figure 102" is the image in chapter 12 or whatever and "Figure 1" is in chapter 1.
Here are my auto-numbering and xref styles, in case that helps (for a v4 stylesheet).
Here are my auto-numbering and xref styles, in case that helps (for a v4 stylesheet).
Code: Select all
p.captionFig
{
margin-bottom: 12pt;
page-break-before: avoid;
mc-auto-number-format: 'GF:Figure {n+}: ';
font-size: 9pt;
margin-top: 3pt;
}
MadCap|xref.figureNumOnly
{
mc-format: '{paranumonly}';
}
Lisa
Eagles may soar, but weasels aren't sucked into jet engines.
Warning! Loose nut behind the keyboard.
-
- Sr. Propeller Head
- Posts: 342
- Joined: Mon Nov 03, 2008 9:33 am
- Location: The heart of America
Re: xref class as print-only?
Would it make a difference if I am using the main xref class instead of creating a subclass? Maybe I should make a xref.figure or something? That is the only difference I am seeing with how you have yours setup. Any text that I put in the mc-format except for what is in the { } will show up in my preview. I don't even get the word figure or anything.
Here is what I have currently
p.figure
{
mc-auto-number-position: inside-head;
font-size: 75%;
font-style: italic;
text-align: center;
line-height: 10pt;
text-decoration: none;
font-weight: normal;
margin-top: 10pt;
margin-bottom: 14pt;
mc-auto-number-offset: 0px;
mc-auto-number-class: Emphasis;
mc-auto-number-format: 'CF:Figure 10-{n+}: ';
}
MadCap|xref
{
mc-format: 'See {paranumonly}';
}
Here is what I have currently
p.figure
{
mc-auto-number-position: inside-head;
font-size: 75%;
font-style: italic;
text-align: center;
line-height: 10pt;
text-decoration: none;
font-weight: normal;
margin-top: 10pt;
margin-bottom: 14pt;
mc-auto-number-offset: 0px;
mc-auto-number-class: Emphasis;
mc-auto-number-format: 'CF:Figure 10-{n+}: ';
}
MadCap|xref
{
mc-format: 'See {paranumonly}';
}
The Moon is the first milestone on the road to the stars.
— Arthur C. Clarke
— Arthur C. Clarke
Re: xref class as print-only?
I don't think that would matter. I have a feeling it's with the properties in your p.figure style. I think you might have some conflicting properties that are causing problems. Make a copy of the stylesheet so you have a backup, then start from scratch with the p.figure style -- add properties back in until it stops working. I'd start with the following in the style then work from there:
Also, if you have any other auto-number formats, make sure they don't use the "F" label as well.
Code: Select all
p.figure
{
mc-auto-number-class: Emphasis;
mc-auto-number-format: 'CF:Figure 10-{n+}: ';
}
Lisa
Eagles may soar, but weasels aren't sucked into jet engines.
Warning! Loose nut behind the keyboard.
-
- Sr. Propeller Head
- Posts: 342
- Joined: Mon Nov 03, 2008 9:33 am
- Location: The heart of America
Re: xref class as print-only?
I deleted out the entire p.figure and something must have been conflicting, because suddenly it views correctly in preview and build. Thank you very much.
The Moon is the first milestone on the road to the stars.
— Arthur C. Clarke
— Arthur C. Clarke