Docs.CanOpenByDblClk - customize info message  SOLVED

PDF-XChange Editor SDK for Developers

Moderators: TrackerSupp-Daniel, Tracker Support, Vasyl-Tracker Dev Team, Sean - Tracker, Paul - Tracker Supp, Chris - Tracker Supp, Tracker Supp-Stefan, Ivan - Tracker Software

Forum rules
DO NOT post your license/serial key, or your activation code - these forums, and all posts within, are public and we will be forced to immediately deactivate your license.

When experiencing some errors, use the IAUX_Inst::FormatHRESULT method to see their description and include it in your post along with the error code.
Post Reply
zarkogajic
User
Posts: 668
Joined: Thu Sep 05, 2019 12:35 pm

Docs.CanOpenByDblClk - customize info message

Post by zarkogajic » Mon Jan 20, 2020 4:23 pm

Hi support,

How to alter the "Documents can be opened by double clicking here..." text which is displayed on an empty doc view area ?

I'm custom allowing documents to be drag-dropped - so would like to add that info also ....

This:

image.png
image.png (30.4 KiB) Viewed 1109 times
-žarko

User avatar
Tracker Supp-Stefan
Site Admin
Posts: 14055
Joined: Mon Jan 12, 2009 8:07 am
Location: London
Contact:

Re: Docs.CanOpenByDblClk - customize info message

Post by Tracker Supp-Stefan » Mon Jan 20, 2020 4:41 pm

Hello Zarko,

This string is translatable - so if you are running a custom localization (it it's a 'custom English' it could only have that string translated) - you can then load your custom translation to the Editor and it will show your custom string.

Regards,
Stefan

zarkogajic
User
Posts: 668
Joined: Thu Sep 05, 2019 12:35 pm

Re: Docs.CanOpenByDblClk - customize info message

Post by zarkogajic » Mon Jan 20, 2020 7:02 pm

Hi Stefan,

Thanks. Can this be done from code?


User avatar
Sasha - Tracker Dev Team
User
Posts: 4937
Joined: Fri Nov 21, 2014 8:27 am
Contact:

Re: Docs.CanOpenByDblClk - customize info message

Post by Sasha - Tracker Dev Team » Tue Jan 21, 2020 4:02 pm

Hello žarko,

The ID of that string is DblClickToOpenDocsTip. The only way of modifying it here is going to the Resources.dat file opening it as a zip file, then going to the Misc folder and updating the Strings.xml file with the needed data.

Cheers,
Alex
Join us at Google+:
https://plus.google.com/+PDFXChangeEditorTS
Subscribe at:
https://www.youtube.com/channel/UC-TwAMNi1haxJ1FX3LvB4CQ

zarkogajic
User
Posts: 668
Joined: Thu Sep 05, 2019 12:35 pm

Re: Docs.CanOpenByDblClk - customize info message

Post by zarkogajic » Tue Jan 21, 2020 4:12 pm

Hi Alex,

Ok, thanks.

p.s.
I'm not a fan of that approach as with the new version of SDK/Resources - I would need to keep in mind to edit again...
So, will just leave it as is.


User avatar
Tracker Supp-Stefan
Site Admin
Posts: 14055
Joined: Mon Jan 12, 2009 8:07 am
Location: London
Contact:

Re: Docs.CanOpenByDblClk - customize info message

Post by Tracker Supp-Stefan » Tue Jan 21, 2020 4:18 pm

Hello Zarko,

Alternatively - you can do a custom 'translation' as I mentioned earlier - and have that loaded immediately after the Editor control.
Your "translation" file will effectively only have the strings you want updated - so it should be relatively small.
You can make a custom translation using this tool:
https://www.tracker-software.com/pdfxed ... zer301.zip

And then e.g. select any flavour of english that is not US (which is the embedded default), and then just supply that file with your project and load the translation from it immediately after the Editor SDK itself. That way even if the resources.dat updates - your translation should not need to.
I believe this is the method you need to call to set the localization to your own translation:
https://sdkhelp.tracker-software.com/vi ... rentUILang

Regards,
Stefan

zarkogajic
User
Posts: 668
Joined: Thu Sep 05, 2019 12:35 pm

Re: Docs.CanOpenByDblClk - customize info message

Post by zarkogajic » Wed May 06, 2020 1:09 pm

Hi Support,

What event should I catch in my custom IUIX_ObjImpl implementation for IPXV_DocumentViewsArea to *not* display the "DblClickToOpenDocsTip" message on it?


p.s.
I think Alex mentioned this possibility (when rendering or something like that) somewhere but I cannot find that post ...

-žarko

User avatar
Sasha - Tracker Dev Team
User
Posts: 4937
Joined: Fri Nov 21, 2014 8:27 am
Contact:

Re: Docs.CanOpenByDblClk - customize info message

Post by Sasha - Tracker Dev Team » Wed May 06, 2020 2:34 pm

Hello zarkogajic,

The drawing of that particular string is done in the e_Render event of the DocumentViewsArea object. If you overload that one and just return S_OK, it won't be drawn (as there is nothing else happening in that method).

Cheers,
Alex
Join us at Google+:
https://plus.google.com/+PDFXChangeEditorTS
Subscribe at:
https://www.youtube.com/channel/UC-TwAMNi1haxJ1FX3LvB4CQ

zarkogajic
User
Posts: 668
Joined: Thu Sep 05, 2019 12:35 pm

Re: Docs.CanOpenByDblClk - customize info message  SOLVED

Post by zarkogajic » Wed May 06, 2020 3:39 pm

Hi Alex,

Great, yes, that was it, thanks!

-žarko

User avatar
Sasha - Tracker Dev Team
User
Posts: 4937
Joined: Fri Nov 21, 2014 8:27 am
Contact:

Docs.CanOpenByDblClk - customize info message

Post by Sasha - Tracker Dev Team » Thu May 07, 2020 6:38 am

:)
Join us at Google+:
https://plus.google.com/+PDFXChangeEditorTS
Subscribe at:
https://www.youtube.com/channel/UC-TwAMNi1haxJ1FX3LvB4CQ

Post Reply