Skip to main content
Participating Frequently
December 21, 2017
Answered

Cross reference figures with short form fig.

  • December 21, 2017
  • 1 reply
  • 1539 views

Hi everybody,

I've been reading how to cross-reference figures in the document. I've been using bullets & numbering in the paragraph style to sequence my figures. I found out how to cross-reference them.

BUT the problem is that my figure in the article appears as "figure 1", but when I want to refer to them within the article I want to use "fig.1" instead of "figure 1". I found the "partial paragraph" function inside the cross-reference function, but what I want is not exactly that, as it has a dot behind the "fig". Can anyone please advise what can be done to archive this?

Thanks a lot!

    This topic has been closed for replies.
    Correct answer vinny38

    Hi

    You could use a Grep style to partially hide some text.

    First set a character style called e.g. "invisible". Set font-size: 0.1pt, tracking: -1000pt and color: none.

    Then, in your cross-reference definition, type Fig. <fullPara>

    At this point, you'd end-up with a cross-reference that shows "Fig. Figure 1 Your text"

    So all you have to do is to hide Figure (and a space)

    Use Grep style to apply "invisible" character style to (?<=Fig.)\sFigure.

    You should be done.

    Vinny

    1 reply

    vinny38
    vinny38Correct answer
    Legend
    December 21, 2017

    Hi

    You could use a Grep style to partially hide some text.

    First set a character style called e.g. "invisible". Set font-size: 0.1pt, tracking: -1000pt and color: none.

    Then, in your cross-reference definition, type Fig. <fullPara>

    At this point, you'd end-up with a cross-reference that shows "Fig. Figure 1 Your text"

    So all you have to do is to hide Figure (and a space)

    Use Grep style to apply "invisible" character style to (?<=Fig.)\sFigure.

    You should be done.

    Vinny

    Participating Frequently
    December 21, 2017

    Hi Vinny,

    Thanks a lot! It worked! Just that now there is a strange space in between the "fig." and "the number. I tried deleting the space in the cross-reference setup to this Fig.<fullPara>, but once I delete that space the Grep doesn't work? Would really appreciate if you can shade a light on this one.

    Thanks!

    vinny38
    Legend
    December 21, 2017

    Are you talking about this "black line"? (see below).

    If so, it's just that the trick basically "hides" the text "Figure", but it's still there.

    So, depending on your preferences, Indd might want to show that there is some text there, even if it's invisible.

    It won't be visible on your PDF, but if you want to get rid of it, go Preferences > Display Performance and set "Greek Type Below" as zero.