Converting v6 project to v7

Please post all questions and comments regarding Help & Manual 7 here.

Moderators: Alexander Halser, Tim Green

appleton
Posts: 37
Joined: Mon Nov 26, 2012 3:40 pm

Converting v6 project to v7

Unread post by appleton »

I use H&M for user documentation for my own software package.

I bought an upgrade from v6 to v7 (with Premium v7 skins) last December, but have not actually used H&M since then. For the last couple of weeks I have been updating my H&M help project in preparation for a new release of my software. To be on the safe side I continued to use v6 to update my documentation which is just about ready now.

It would be great if I could convert this to a v7 project before release so that I could have an EWriter output file instead of CHM, but I'm a bit short of time.

My current v6 project uses the WebHelp_SlateBlue.hmskin and CHM_LightBlue.hmskin skins with a couple of slight tweaks to do "clearall" for images and sub-headings (as per my past forum questions). My project is fairly simple, just text and images, and just has a few basic text styles.

Is there a quick and painless way of converting my v6 project to v7 and utilizing some of the new v7 Premium skins ?
User avatar
Tim Green
Site Admin
Posts: 23143
Joined: Mon Jun 24, 2002 9:11 am
Location: Bruehl, Germany
Contact:

Re: Converting v6 project to v7

Unread post by Tim Green »

Is there a quick and painless way of converting my v6 project to v7 and utilizing some of the new v7 Premium skins ?
Just open the project in Help+Manual 7, choose the new skin you want to use and publish away. That's it! The project formats are directly compatible -- you can even edit and publish HM7 projects with HM6. The only difference is that features not supported in HM6 will be added to your project files when you save with HM7. And if you edit and save a HM7 project with HM6 any unknown features will simply be discarded from the XML. For example, if you create multiple TOCs with HM7 and then edit and save the same project with HM6, the additional TOCs will be deleted and you will only have your main TOC.

Merry Christmas! :santa:
Regards,
Tim (EC Software Documentation & User Support)

Private support:
Please do not email or PM me with private support requests -- post to the forum directly.
appleton
Posts: 37
Joined: Mon Nov 26, 2012 3:40 pm

Re: Converting v6 project to v7

Unread post by appleton »

Thanks Tim. I have decided to abandon CHM for my new release, so I will just be producing EWriter instead. And Webhelp too.

I decided to start with the V3 Premium skin "Flat_Blue_Diamond_EWriter.hmskin" and have manually edited it for my own product name and web site address. It works well with my existing project as you said it would. But there are a couple of things I need to fix.

When I was using H&M6 and the older webhelp premium skin, I needed the Heading2 and some images to have the style "clear : both" so that sensible gaps could be left in the flow of text - you helped me with this in the following thread:

https://helpman.it-authoring.com/viewto ... 892#p55892

With your suggestions, I found that the fix was to insert the following into the skin's HTML_Page_templates>Default

<noscript><style type="text/css">
img#hmclearfix { clear: both; }
.p_Heading2 /* Heading2 */ { clear: both; }
</style>
<noscript>

which worked exactly as I needed with Heading2 headings, and with images (where the image's Picture ID was set to "hmclearfix".

But this doesn't seem to do anything using v7 with the "Flat_Blue_Diamond_EWriter.hmskin" skin.

How do I get the clear:both fix working again in v7 with that skin ?
appleton
Posts: 37
Joined: Mon Nov 26, 2012 3:40 pm

Re: Converting v6 project to v7

Unread post by appleton »

OK - my fault. The inserted text should be

<style type="text/css">
img#hmclearfix { clear: both; }
.p_Heading2 /* Heading2 */ { clear: both; }
</style>

without being enclosed in "noscript".

But I do still get warning messages about "Duplicate anchor ID/name "hmclearfix"". You mentioned that this was an illegal way of getting the clear:both to work for images but a better way might be available in the forthcoming version 7. Now that I'm using version 7 is there a better way than using the hmclearfix ID ?

Also, my header logo PNG file is wider than the H&M logo-image-desk.png and the right of it is truncated in the output file. How do I modify the skin so that it will display the full width of my logo ?

Finally, the EWriter window banner has a red "Short Title" button on it. When you click it one of the menu items is "About Help&Manual" - how do I change the "Short Title" text to something useful, and the text and URL of the"About Help&Manual" to my own web site ?
User avatar
Tim Green
Site Admin
Posts: 23143
Joined: Mon Jun 24, 2002 9:11 am
Location: Bruehl, Germany
Contact:

Re: Converting v6 project to v7

Unread post by Tim Green »

The V3 skins do quite a lot dynamically, and even if you put CSS in the template it may not work when browsing to new topics. What you need is to add it to the actual CSS file itself. In the EWriter skins there is only one file to edit (in the WebHelp skins there are three, one each for desktop, phone and tablet modes): hmwebhelp_main_desktop.css. Edit that file and locate the following lines:

Code: Select all

/* Layout of printable version for browser print function */
@media only print {
Insert your lines directly before this, without <script> tags:

Code: Select all

img#hmclearfix { clear: both; }
.p_Heading2 /* Heading2 */ { clear: both; }

/* Layout of printable version for browser print function */
@media only print {
But I do still get warning messages about "Duplicate anchor ID/name "hmclearfix"". You mentioned that this was an illegal way of getting the clear:both to work for images but a better way might be available in the forthcoming version 7. Now that I'm using version 7 is there a better way than using the hmclearfix ID ?
In HM7 you can now add classes to images as well as IDs. This will mean editing all your images, and so long as everything is working you don't really need to do it. You can just ignore the message. If you do want to make the change, double-click on the image to open its editing dialog. Then delete the Picture ID: and enter the name in the HTML Class: field instead. You will then need to change img#hmclearfix in your CSS code to img.hmclearfix (the pound sign references IDs, the dot references classes).
Regards,
Tim (EC Software Documentation & User Support)

Private support:
Please do not email or PM me with private support requests -- post to the forum directly.
appleton
Posts: 37
Joined: Mon Nov 26, 2012 3:40 pm

Re: Converting v6 project to v7

Unread post by appleton »

Fantastic! Thanks Tim.

I also just found where to change the "short title" button and menu - it is in the project file settings (not the skin).

For possible future use, is there a way of "diff-ing" a customized skin file against the untouched version ? This would make it easy to change to a different skin by listing the changes I had made to the existing skin and then I could quickly make the same changes in the second skin.
User avatar
Tim Green
Site Admin
Posts: 23143
Joined: Mon Jun 24, 2002 9:11 am
Location: Bruehl, Germany
Contact:

Re: Converting v6 project to v7

Unread post by Tim Green »

appleton wrote:For possible future use, is there a way of "diff-ing" a customized skin file against the untouched version ? This would make it easy to change to a different skin by listing the changes I had made to the existing skin and then I could quickly make the same changes in the second skin.
If you have just changed configuration settings etc. you can do this with the Toolbox utility (in the Toolbox File menu). If you have also made changes to templates and added your own baggage files etc. you can try doing it with a diffing tool, if you're very careful:
  1. Change the extensions of the old and new skins from .hmskin to .zip, then unpack them into two separate empty folders.
  2. Diff and merge with WinMerge or Beyond Compare or a similar tool.
  3. Repack and change the extension back to .hmskin
If you are doing this from one version to another and JavaScript files have changed, just keep the new JS files. They are compressed for maximum performance and you don't need to keep anything from the old versions.
Regards,
Tim (EC Software Documentation & User Support)

Private support:
Please do not email or PM me with private support requests -- post to the forum directly.
appleton
Posts: 37
Joined: Mon Nov 26, 2012 3:40 pm

Re: Converting v6 project to v7

Unread post by appleton »

Thanks Tim.

I think I've found a minor bug in the compiled EWriter exe file.

I have a few anchors located at the beginning of Heading2 titles so that I can link directly to a location part way through a page - as you know, the page will be automatically scrolled to the location and the heading will flash. When my program spawns the EWriter EXE file I am passing these locations as the 1st argument like this:

mypage.html?anchor=myanchor1

This works well except that when the EWriter window appears, the page positions itself just below the Heading2 text - so the Heading2 text is not visible because it is "obscured" by the navigation/breadcrumb bar.

If I then click one of the other entries in the left-hand topic list to navigate to any different page, and then click the back button on the window title bar, the original page is displayed again but with the Heading2 text positioned correctly this time. If my program then spawns the EWriter EXE file again with the same location the existing window will position itself incorrectly again (as described above).

So the positioning in general does seem to be OK, but the problem seem to lie when the EWriter window is first spawned or when the location is sent to an existing EWriter window.
User avatar
Tim Green
Site Admin
Posts: 23143
Joined: Mon Jun 24, 2002 9:11 am
Location: Bruehl, Germany
Contact:

Re: Converting v6 project to v7

Unread post by Tim Green »

appleton wrote:I think I've found a minor bug in the compiled EWriter exe file.

No, that's not a bug you found -- it's one you created. 8)

Your modification is making it impossible for the scripts to calculate the height of the page correctly and position the page accordingly when scrolling. You need to decide what you want here: Either arbitrarily collapse content on the page and accept that the height of the page can no longer be calculated correctly, or leave it as it is. If you leave it as it is you will need to position the anchor further up to compensate for the offset of your collapsed content. :?
Regards,
Tim (EC Software Documentation & User Support)

Private support:
Please do not email or PM me with private support requests -- post to the forum directly.
appleton
Posts: 37
Joined: Mon Nov 26, 2012 3:40 pm

Re: Converting v6 project to v7

Unread post by appleton »

to compensate for the offset of your collapsed content
I don't have any collapsed content. All of the pages are pretty simple - paragraphs of Normal text with occasional Header2 headings, IPP images and tables.

I have now tried publishing my project using the UNTOUCHED skin file Flat_Blue_Diamond_EWriter.hmskin that is an exact copy of the file from the Premium Pack 3.41 and the same problem exists. So I don't think the problem is with the skin file.

The EWriter exe file MUST be calculating the page height correctly because it can position the anchor/Heading2 correctly if you click the menu to go to another page, and then click back using small left arrow button at the top left of the window title bar. If it could not calculate the page height correctly then clicking back would go to to the same incorrect position, but it actually gets the position correct.

LATER: OK I tried creating a brand new empty project in H&M 7, imported the styles from my old/existing project, then created a couple of new topics with the same names as in the old project, then did a simple copy and paste of the contents of the topics from the existing project to the new project. Then I did an EWriter Publish from the new project using the untouched Flat_Blue_Diamond_EWriter.hmskin. I then tested spawning the EWrite EXE with the same arguments as before - THIS WORKS PERFECTLY! At least it does with the 2 anchors I've tried so far.

The only conclusion I can come to is that there is something in the old v6 project file that is messing up the EWriter positioning (but only when spawning it).

The only workaround seems to be to manually create all of the topics in the new project again, and then copy/paste the contents of each topic from the old project to the new project - I'm not looking forward to this. :(

Is there anything you can suggest that might be causing the problem in the project file? If not I'll just have to laboriously copy the whole project content across.
appleton
Posts: 37
Joined: Mon Nov 26, 2012 3:40 pm

Re: Converting v6 project to v7

Unread post by appleton »

I had to press on, so I've now copied all of the topics across - it wasn't as tedious as I expected.

The EWriter seems to be positioning correctly now.

I'm completely mystified as to the cause of the problem but as least it seems to be OK with the new v7 project file.
User avatar
Tim Green
Site Admin
Posts: 23143
Joined: Mon Jun 24, 2002 9:11 am
Location: Bruehl, Germany
Contact:

Re: Converting v6 project to v7

Unread post by Tim Green »

Is there anything you can suggest that might be causing the problem in the project file? If not I'll just have to laboriously copy the whole project content across.
That's very odd. If you can mail me a small demo project with which it can be reproduced at support AT ec-software.com (replace the AT with @) I'd be happy to check it.
Regards,
Tim (EC Software Documentation & User Support)

Private support:
Please do not email or PM me with private support requests -- post to the forum directly.
appleton
Posts: 37
Joined: Mon Nov 26, 2012 3:40 pm

Re: Converting v6 project to v7

Unread post by appleton »

Thanks for the offer Tim. I have spent quite a lot of time trying to get around the problem, so I think I'll just stick with this new v7 project which seems to work OK.

I don't have a tiny project that demonstrates the problem. I think only my full project did this. If you definitely want to investigate the cause I would be happy to email my whole project which is about 15MB zipped-up. Let me know if you want it, but otherwise I'm happy for the issue to be closed.
User avatar
Tim Green
Site Admin
Posts: 23143
Joined: Mon Jun 24, 2002 9:11 am
Location: Bruehl, Germany
Contact:

Re: Converting v6 project to v7

Unread post by Tim Green »

Just put it in a Dropbox folder or similar and mail me the link at support AT ec-software.com (replace the AT with @) and I'll check it out. I'd really like to see what is going on here. Please include a brief text explaining what links and topics to use to reproduce the issue.
Regards,
Tim (EC Software Documentation & User Support)

Private support:
Please do not email or PM me with private support requests -- post to the forum directly.
appleton
Posts: 37
Joined: Mon Nov 26, 2012 3:40 pm

Re: Converting v6 project to v7

Unread post by appleton »

OK, you have mail. :)
Post Reply