After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 100476 - Keycap rendered incorrectly in bold
Keycap rendered incorrectly in bold
Status: RESOLVED FIXED
Product: yelp
Classification: Applications
Component: XSLT
git master
Other other
: Normal minor
: ---
Assigned To: Mikael Hallendal
Yelp maintainers
Depends on:
Blocks:
 
 
Reported: 2002-12-05 23:26 UTC by Eugene O'Connor
Modified: 2004-12-22 21:47 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Test file for comparison of keycombo and keycap (491 bytes, text/xml)
2002-12-06 05:04 UTC, Eric Baudais
  Details
Patch for yelp-custom.xsl to fix keycombo inconsistency. (1.37 KB, patch)
2002-12-06 05:51 UTC, Eric Baudais
none Details | Review
patch to fix keycombo tag (457 bytes, patch)
2003-02-18 02:09 UTC, Alexander Kirillov
none Details | Review
Make keycap bold iff it is not in a table (630 bytes, patch)
2003-07-08 02:47 UTC, Shaun McCance
none Details | Review
Make keycap never bold. (613 bytes, patch)
2003-07-08 02:48 UTC, Shaun McCance
none Details | Review

Description Eugene O'Connor 2002-12-05 23:26:34 UTC
When the keycap tag is used with keycombo, the text is rendered as normal 
text. This is correct. When the keycap tag is used alone it is displayed 
in bold. This is in correct.
Comment 1 Eric Baudais 2002-12-06 05:04:18 UTC
Created attachment 12788 [details]
Test file for comparison of keycombo and keycap
Comment 2 Eric Baudais 2002-12-06 05:04:40 UTC
I think the mistake is the keycombo should be bold and the keycap is
correctly bolded.  The keycombo and keycaps need to be set apart from
the text because it is an instruction to the user to press a certain
key or sequence of keys.  The boldness lets the user easily reference
which keys should be pressed.

I have also made a test file so the two can be compared side by side.
Comment 3 Eric Baudais 2002-12-06 05:51:13 UTC
Created attachment 12789 [details] [review]
Patch for yelp-custom.xsl to fix keycombo inconsistency.
Comment 4 Chris Lyttle 2002-12-06 06:01:42 UTC
I agree, the docbook.org website has it defined as bold too

http://docbook.org/tdg/en/html/keycap.html
Comment 5 Sander Vesik 2002-12-06 13:39:17 UTC
so just to clarify - *both* should be bold ?
Comment 6 Eugene O'Connor 2002-12-06 14:57:02 UTC
The reason I went for normal formatting rather than bold formatting 
was because in some places I list many keycombos/keycaps in table 
format (see Desktop > Basic Skills > Keyboard Skills). In this case, 
I felt that bolding would be an eyesore.

But I don't feel very strongly about it, I see Eric's point too. As 
long as individual keycaps and keycaps in keycombos are rendered 
consistently, I'm happy.
Comment 7 Alexander Kirillov 2003-02-18 02:03:24 UTC
The patch suggested by Eric just removes all <keycombo> customization.
This customization was there for a reason: it replaces "-" used to
join  keys by "+", so it becomes, e.g. Alt+F1, not Alt-F1 (at some
moment, it was decided that + looks better). 

I am attaching a different patch which keeps the customization and
fixes it so that now <keycap> is bold both in <keycombo> and outisde
of it. 
Comment 8 Alexander Kirillov 2003-02-18 02:09:25 UTC
Created attachment 14403 [details] [review]
patch to fix keycombo tag
Comment 9 Mikael Hallendal 2003-03-31 21:45:56 UTC
Hmm .. which one is the one we want?
Comment 10 Shaun McCance 2003-04-25 23:49:23 UTC
We should apply Alexander's patch.  As he points out, the custom
template changes the default joinchar from "-" to "+".  However, this
custom template has another difference from nwalsh's template.  It
effectively only apples templates to the keycombo's grandchildren,
bypassing any formatting that the stylesheets would do to tags like
keycap.  Alexander's patch fixes this.

Also, Alexander's patch should be applied regardless of how we want
keycaps rendered.  The current stylesheet doesn't even allow children
of keycombo to hit a template.  If we want to override what keycombo
children are formatted, we should explicitly override templates for
tags like keycap, rather than just preventing them from being processed.

Note that if we would like keycombos and keycaps not to be bolded when
listed in a table, I can add that customization in while still leaving
them bold if they occur inside normal text.
Comment 11 Eric Baudais 2003-06-17 21:08:59 UTC
Alexander's patch has been committed to Yelp HEAD and to
gnome-docu/gdp/xsl in CVS.

Do we want the keycap and keycombo tags to be bolded in tables as well?
Comment 12 Eugene O'Connor 2003-06-19 10:07:23 UTC
Keycap and keycombo tags should be formatted consistently wherever
they are located. If keycap and keycombo tags are rendered in bold in
body text, then I think they should also be rendered in bold in
tables. 

I think the consistency of how they are rendered is more important
than avoiding the minor visual problem of a lot of bold in a table. So
I don't think we need to apply the customization that Shaun suggests.
Comment 13 Shaun McCance 2003-07-08 02:46:47 UTC
All right, so this can go three ways:

- keycap is always bold (current behavior in HEAD)
- keycap is never bold
- keycap is bold, except when in a table

For reference, I'm attaching two patches for the second two cases. 
However, I think we should stick with the current behavior.
Comment 14 Shaun McCance 2003-07-08 02:47:42 UTC
Created attachment 18117 [details] [review]
Make keycap bold iff it is not in a table
Comment 15 Shaun McCance 2003-07-08 02:48:14 UTC
Created attachment 18118 [details] [review]
Make keycap never bold.
Comment 16 Mikael Hallendal 2003-08-15 05:01:58 UTC
Closing on request of Shaun. Thanks.