Bug 68346 - ACCESSIBILITY: Accessibility bridge should expose the font name
Summary: ACCESSIBILITY: Accessibility bridge should expose the font name
Status: RESOLVED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: UI (show other bugs)
Version:
(earliest affected)
3.3.0 release
Hardware: Other Windows (All)
: medium normal
Assignee: Niklas Johansson
URL:
Whiteboard: target:4.2.0
Keywords:
Depends on:
Blocks: a11y-Windows
  Show dependency treegraph
 
Reported: 2013-08-20 17:19 UTC by Niklas Johansson
Modified: 2014-04-14 11:25 UTC (History)
1 user (show)

See Also:
Crash report or crash signature:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Niklas Johansson 2013-08-20 17:19:42 UTC
The font name should be exposed to the accessibility bridge as the characterattribute called fontfamily. At the moment the information given to the Accessibility bridge is if the font is Monospaced or Proportional.

I'm not completely sure but I believe that exchanging the attribute "CharFontPitch", with "CharFontName" here:
http://opengrok.libreoffice.org/xref/core/accessibility/bridge/org/openoffice/java/accessibility/AccessibleTextImpl.java#37

Adjusting the following if-else-block to expose the attribute:
http://opengrok.libreoffice.org/xref/core/accessibility/bridge/org/openoffice/java/accessibility/AccessibleTextImpl.java#298

Might fix the problem, but probably there is more to it.

I'm not currently able to build on Windows, so I can't really try it out either. :(

The issue seems to be inherited from OpenOffice.org so I'm setting 3.3.0 as version.
Comment 1 Caolán McNamara 2013-09-01 19:38:19 UTC
Maybe the original code did this because the docs mention "Monospaced", but googling around I see plenty of examples of setting real font names via setFontFamily so it seems to make sense to do that instead.

http://docs.oracle.com/javase/1.4.2/docs/api/javax/swing/text/StyleConstants.html#getFontFamily%28javax.swing.text.AttributeSet%29
Comment 2 Commit Notification 2013-09-01 19:46:48 UTC
Niklas Johansson committed a patch related to this issue.
It has been pushed to "master":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=277b339371727134851da1b695d9d8d30889a961

fdo#68346 Accessibility bridge should exspose the font name.



The patch should be included in the daily builds available at
http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
http://wiki.documentfoundation.org/Testing_Daily_Builds
Affected users are encouraged to test the fix and report feedback.