You are here

[Fixed] LibreCAD leaves Qt filedialog

13 posts / 0 new
Last post
Simeon
Simeon's picture
Offline
Last seen: 10 years 1 month ago
DeveloperTranslator
Joined: 2006-09-25 15:15
[Fixed] LibreCAD leaves Qt filedialog

I run LibreCAD on Win 7 and opened a file. This causes the QT filesave part to appear in the registry which isnt backed up/deleted/taken care of:

----------------------------------
Keys added:
----------------------------------
HKCU\Software\Trolltech
HKCU\Software\Trolltech\OrganizationDefaults
HKCU\Software\Trolltech\OrganizationDefaults\Qt

----------------------------------
Values added:
----------------------------------
HKCU\Software\Trolltech\OrganizationDefaults\Qt\filedialog:  40 00 42 00 79 00 74 00 65 00 41 00 72 00 72 00 61 00 79 00 28 00 00 00 00 00 00 00 BE 00 00 00 00 00 00 00 03 00 00 00 00 00 00 00 1E 00 00 00 00 00 00 00 FF 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 02 00 00 00 00 00 00 00 72 00 00 00 00 00 0E 00 00 00 01 00 00 00 00 00 00 00 05 00 01 00 00 00 00 00 00 00 01 00 00 00 00 00 00 00 02 00 00 00 00 00 00 00 05 00 66 00 69 00 6C 00 65 00 3A 00 00 00 00 00 00 00 17 00 66 00 69 00 6C 00 65 00 3A 00 2F 00 2F 00 2F 00 43 00 3A 00 2F 00 55 00 73 00 65 00 72 00 73 00 2F 00 73 00 6B 00 75 00 65 00 68 00 6C 00 00 00 00 00 00 00 01 00 00 00 00 00 00 00 18 00 00 00 44 00 00 00 3A 00 00 00 5C 00 00 00 44 00 00 00 6F 00 00 00 63 00 00 00 75 00 00 00 6D 00 00 00 65 00 00 00 6E 00 00 00 74 00 00 00 73 00 00 00 00 00 00 00 18 00 00 00 44 00 00 00 3A 00 00 00 2F 00 00 00 44 00 00 00 6F 00 00 00 63 00 00 00 75 00 00 00 6D 00 00 00 65 00 00 00 6E 00
 00 00 74 00 00 00 73 00 00 00 00 00 00 00 7E 00 00 00 00 00 00 00 FF 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 01 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 01 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 01 00 8D 00 00 00 00 00 00 00 04 00 01 00 01 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 64 00 FF 00 FF 00 FF 00 FF 00 00 00 00 00 00 00 81 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 04 00 00 00 00 00 00 00 D0 00 00 00 00 00 00 00 01 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 32 00 00 00 00 00 00 00 01 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 32 00 00 00 00 00 00 00 01 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 59 00 00 00 00 00 00 00 01 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 01 00 29 00

EDIT:

As I fix I added

[RegistryKeys]
-=HKCU\Software\Trolltech\OrganizationDefaults\Qt

to a QT app I am working on. This works, but I hope I am not harming other QT apps with this rather wide approach of deleting the whole key.

EDIT2:
I regshotted my fix and it restores pre-existing keys without issue so it should be safe.

vf2nsr
vf2nsr's picture
Offline
Last seen: 8 years 1 month ago
Developer
Joined: 2010-02-13 17:10
Will look

Thanks I guess they changed things as it do did not leave them previously

“Be who you are and say what you feel because those who mind don't matter and those who matter don't mind.” Dr. Seuss

Simeon
Simeon's picture
Offline
Last seen: 10 years 1 month ago
DeveloperTranslator
Joined: 2006-09-25 15:15
I know

Looks like they switched to a newer version of QT.

"What about Love?" - "Overrated. Biochemically no different than eating large quantities of chocolate." - Al Pacino in The Devils Advocate

vf2nsr
vf2nsr's picture
Offline
Last seen: 8 years 1 month ago
Developer
Joined: 2010-02-13 17:10
Thanks

I have corrected it and sending to John as we type so to say. Many thanks Simeon I appreciate the heads up on it and added your code as well

“Be who you are and say what you feel because those who mind don't matter and those who matter don't mind.” Dr. Seuss

Simeon
Simeon's picture
Offline
Last seen: 10 years 1 month ago
DeveloperTranslator
Joined: 2006-09-25 15:15
youre welcome

Testing apps that are already released for changes such as this one is a tedious business I gave up some time ago. Maybe it would be good to have some coordinated effort of some devs to do this but that didnt work with Dev Tests so it will probably not work here either.

"What about Love?" - "Overrated. Biochemically no different than eating large quantities of chocolate." - Al Pacino in The Devils Advocate

vf2nsr
vf2nsr's picture
Offline
Last seen: 8 years 1 month ago
Developer
Joined: 2010-02-13 17:10
It was my fault

As I did it on my Win Hate machine which had it installed and not the clean Win 7 machine got a little lazy and did not run the regshot

“Be who you are and say what you feel because those who mind don't matter and those who matter don't mind.” Dr. Seuss

John T. Haller
John T. Haller's picture
Offline
Last seen: 6 hours 59 min ago
AdminDeveloperModeratorTranslator
Joined: 2005-11-28 22:21
RegistryValueBackupDelete

Doing that whole key will break pretty much everything stored by any Qt apps during execution. A better option is to use RegistryValueBackupDelete just on the filedialog value. It would still be possible for two apps to collide on it, but it decreases the collision scope significantly. We'll need to handle the Qt key cleanup, but the two parent keys (rganizationDefaults and Trolltech) are handled by PAL's Qt handling which is already configured. So, we need to add:

[RegistryValueBackupDelete]
1=HKCU\Software\Trolltech\OrganizationDefaults\Qt\filedialog

[RegistryCleanupIfEmpty]
1=HKCU\Software\Trolltech\OrganizationDefaults\Qt

Sometimes, the impossible can become possible, if you're awesome!

Simeon
Simeon's picture
Offline
Last seen: 10 years 1 month ago
DeveloperTranslator
Joined: 2006-09-25 15:15
Ah!

Thats what that section is for. I readit 3 times but couldnt figure out what it was useful for.

Besides, I realised the possible downsides of my proposal but couldnt find a way to get a better result. Thanks John for the help.

"What about Love?" - "Overrated. Biochemically no different than eating large quantities of chocolate." - Al Pacino in The Devils Advocate

John T. Haller
John T. Haller's picture
Offline
Last seen: 6 hours 59 min ago
AdminDeveloperModeratorTranslator
Joined: 2005-11-28 22:21
Fixed

This is fixed in LibreCAD Portable 1.0.4 Rev 2.

Simeon et al, be sure to look at my updated launcher code above for your own apps.

Sometimes, the impossible can become possible, if you're awesome!

vf2nsr
vf2nsr's picture
Offline
Last seen: 8 years 1 month ago
Developer
Joined: 2010-02-13 17:10
Thanks John

Smile

“Be who you are and say what you feel because those who mind don't matter and those who matter don't mind.” Dr. Seuss

Simeon
Simeon's picture
Offline
Last seen: 10 years 1 month ago
DeveloperTranslator
Joined: 2006-09-25 15:15
[RegistryCleanupIfEmpty]

In Johns update, there is this part:

[RegistryCleanupIfEmpty]
1=HKCU\Software\Trolltech\OrganizationDefaults\Qt

Shouldnt this include this too:

2=HKCU\Software\Trolltech\OrganizationDefaults
3=HKCU\Software\Trolltech

"What about Love?" - "Overrated. Biochemically no different than eating large quantities of chocolate." - Al Pacino in The Devils Advocate

John T. Haller
John T. Haller's picture
Offline
Last seen: 6 hours 59 min ago
AdminDeveloperModeratorTranslator
Joined: 2005-11-28 22:21
Handled

We'll need to handle the Qt key cleanup, but the two parent keys (OrganizationDefaults and Trolltech) are handled by PAL's Qt handling which is already configured.

Sometimes, the impossible can become possible, if you're awesome!

Simeon
Simeon's picture
Offline
Last seen: 10 years 1 month ago
DeveloperTranslator
Joined: 2006-09-25 15:15
Oh

Thanks. Should have read that more often.

"What about Love?" - "Overrated. Biochemically no different than eating large quantities of chocolate." - Al Pacino in The Devils Advocate

Log in or register to post comments