When requesting formatting information, default colors are now explicitely reported in Wordpad and other edit fields#13942
Conversation
…itely reported in Wordpad and other edit fields.
See test results for failed build of commit 85d724fa09 |
|
I realize that the issue is broader since "Default color" is also reported in MS Word when the color is "Automatic". Converting to draft while investigating further. |
lukaszgo1
left a comment
There was a problem hiding this comment.
Since there at least two other places (support for pre UIA dropdowns in Excel, and retrieval of highlight colors in display model) where GetSysColor is used it makes sens to create a wrapper around it in winUser, and an IntEnum which defines values representing known display elements this function accepts.
|
I have opened #13959 to discuss how default colors need to be reported more generally. |
…te automatic instead of default.
|
I have updated the code and the initial description taking into account what was discussed in #13959 (Cc @feerrenrut). I still have to create a wrapper for |
|
This PR is now ready to review again. Note for those who have reviewed it at the beginning: Please re-read the initial description that have been modified. Also, I have made a wrapper for
|
See test results for failed build of commit becfe662f3 |
|
|
Many thanks @lukaszgo1 for these tests. |
seanbudd
left a comment
There was a problem hiding this comment.
Generally looks good to me, thanks @CyrilleB79
seanbudd
left a comment
There was a problem hiding this comment.
Thanks @CyrilleB79 , looks almost ready
Link to issue number:
Fixes #13959
Summary of the issue:
In Wordpad or in log viewer, pressing NVDA+F reports "default color on default color" as color information in formatting information. This information is of no use to know the color really displayed, what may be necessary when working with sighted persons.
Description of user facing changes
Description of development approach
According to the CHARFORMATW structure for the class
EditTextInfoand to ITextFont::GetForeColor for the classITextDocumentTextInfo, the system colors are used for default colors. Thus, I retrieve these colors in these cases.Testing strategy:
Manual tests:
For the class
ITextDocumentTextInfo:For the class
EditTextInfo, I have performed the same tests, making previously the changes in #11897 (comment).Known issues with pull request:
Change log entries:
Bug fixes
When requesting formatting information, colors are now explicitly reported in Wordpad or log viewer, rather than only "Default color". (#13959)Code Review Checklist: