The native hhctrl.ocx does not have any resrouce strings. My understanding is that we have them in Wine because we use them as tooltips for the toolbar items. That's good I guess.
However a number of them make no sense at all and are a pain to translate. For instance:
IDTB_NOTES "IDTB_NOTES" IDTB_BROWSE_FWD "IDTB_BROWSE_FWD" IDTB_BROWSE_BACK "IDT_BROWSE_BACK"
or
IDTB_JUMP1 "Jump1" IDTB_JUMP2 "Jump2"
What's the difference between 'Jump1' and 'Jump2'?
Also I have found no proper documentation on this. So does anyone know what to put there so we have strings that correctly describe what these toolbar buttons do?
What's the difference between 'Jump1' and 'Jump2'?
Both are, it appears, toolbar buttons that can be customised by the help file developer and used to link to individual topics or URLs. The captions are customisable. The strings "Jump1" and "Jump2" themselves, as far as I can tell, should never be displayed to the user.
On Mon, 22 Aug 2011, Owen Rudge wrote:
What's the difference between 'Jump1' and 'Jump2'?
Both are, it appears, toolbar buttons that can be customised by the help file developer and used to link to individual topics or URLs. The captions are customisable. The strings "Jump1" and "Jump2" themselves, as far as I can tell, should never be displayed to the user.
I see the strings being added to the toolbar with
LPWSTR szBuf = HH_LoadString(buttons[dwIndex].idCommand); ... buttons[dwIndex].iString = (DWORD)SendMessageW(hToolbar, TB_ADDSTRINGW, 0, (LPARAM)szBuf);
But from there it's not clear to me they whether they will be used or not. Did you specifically mean that only Jump1/2 would not be used or does that apply to the other IDTB_XXX strings too?
And if they are never shown to the user should be no issue with removing them, right? (or replacing them with hardcoded strings in the source)
I see the strings being added to the toolbar with
LPWSTR szBuf = HH_LoadString(buttons[dwIndex].idCommand); ... buttons[dwIndex].iString = (DWORD)SendMessageW(hToolbar, TB_ADDSTRINGW, 0, (LPARAM)szBuf);
But from there it's not clear to me they whether they will be used or not. Did you specifically mean that only Jump1/2 would not be used or does that apply to the other IDTB_XXX strings too?
I was referring specifically to Jump1/2 in this case. They do get used, particularly as it looks like we don't currently replace them with the custom text.
However, the "IDTB" strings that we have are all noted as "unimplemented" in Microsoft's htmlhelp.h file, and in theory nobody should be using them. Considering we don't support any of them in TB_AddButtonsFromFlags, I think the resource entries for them can be removed.
James does seem to have added support for creating the toolbar buttons for IDTB_TOC_NEXT/PREV, but I can't find any documentation on what they're meant to do, and he added no actual functionality, so they can probably go too.
On Mon, 22 Aug 2011, Owen Rudge wrote: [...]
But from there it's not clear to me they whether they will be used or not. Did you specifically mean that only Jump1/2 would not be used or does that apply to the other IDTB_XXX strings too?
I was referring specifically to Jump1/2 in this case. They do get used, particularly as it looks like we don't currently replace them with the custom text.
Support for Jump 1/2 does not seem to be implemented though (see TB_OnClick()). So they would not do anything which would confuse users.
So I propose the attached patch.
So I propose the attached patch.
I wouldn't object to that. If somebody wants to implement support for the Jump buttons in the future, they can always be re-added, although I would say that in such a circumstance, a resource file entry wouldn't be necessary anyway.
However a number of them make no sense at all and are a pain to translate. For instance:
IDTB_NOTES "IDTB_NOTES" IDTB_BROWSE_FWD "IDTB_BROWSE_FWD" IDTB_BROWSE_BACK "IDT_BROWSE_BACK"
With regards to these buttons, attempting to use those constants on Windows results in buttons (captioned "Notes", "Next", "Previous") with no apparent functionality whatsoever. Microsoft's own documentation suggests these are "not implemented". I expect we could remove those from Wine's hhctrl without any great consequences.