Simulating A-links in browser Help (single sourcing question

Nothing is perfect! This is where you can post your ideas and wishes for functions you'd like to see in Help & Manual. Current version only please (H&M7).

Moderators: Alexander Halser, Tim Green

Post Reply
User avatar
brunos
Posts: 218
Joined: Sun Jul 07, 2002 4:27 pm
Location: Bologna, Italy
Contact:

Simulating A-links in browser Help (single sourcing question

Unread post by brunos »

I was recently astonished finding out that A-links do not work with uncompiled help - they're just wiped out when you export your project as HTML. Worse than this: if you didn't make them as conditional text, they remain in your text as "lead-to-nothing" calls, as "Related topic" without even a link. My fault - I just didn't know it, but even Microsoft claims it's not possible at all: http://msdn.microsoft.com/library/defau ... topics.asp.

What a pity! So, I can have them in CHM, but non in HTML export? Another thombstone on a single source hopes?

I think that (perhaps) there could be a nice workaround for this limitation.
I imagine it to work in the following way (don't know if that would be a reasonable or the best way to do it; and if it is possible at all):

1. You click where you want links to be inserted.
2. You click a related icon or press a shortcut key
3. Help & Manual checks if the current topic has A-keywords specified.
4. If there are no A-keywords in the current topic, it stops.
5. If there are A-keywords in the current topic, it parses entire project (see objections and notes), and build's an array of captions and IDs of topics which share the same A-keyword
6. It inserts them, one after another, in a line, separated by comma, at the position of the cursor.

So you have something as:
Caption1, Caption2, Caption3, Caption4,

Now, objections and notes:
------------
Objection 1: It will be slow as death.
Defence 1: Not slower than global search and replace, and there's a big benefit compared to doing it manually
------------
Objection 2: It will be static. If you add the already used keyword to a new topic, you will have to redo *ALL* links.
Defence 2: This one is a bad one. Don't know how to answer it. Except by "is something, better than nothing"?
------------
Objection 3: What about other modules which may share the same A-keyword?
Defence 3: This is also a bad one. I don't know the answer either. The real A-links in modular help are resolved at run-time, while the "simulation" has to be resolved at the design time. Perhaps we could make it use a list of HM3 files that will be merged at run time, similar to what [MERGE FILES] does? So it will parse all files, instead one only? Then it would be even slower...
--------

Forum folks, I would like to have your feedback on this. And, of course, Alexander's one.

Regards,
Bruno
Post Reply