Jump to content
Developer Wiki and Function Reference Links ×

Dark Mode Preference Selector


Recommended Posts

I'm trying to get the preference selector to detect whether or not the user has Dark Mode enabled.  In the VW2024 offline function reference, there is selector 6756, but it also is the same selector for Entered in Group and is returning false to me regardless of what my dark mode settings are, so I'm guessing that it's not correct.

 

image.thumb.png.98f7152d9cb9478c8fec06195ec7ddcd.png

Link to comment

Also, FWIW, Entered in Group which is also listed as 6756 might be 6755 as defined on the next line:

varGetEnteredGroupHandle = 6755, // Handle read - Get the Handle of the current opened for edit group in VW document.

 

BUT, is it?

 

I have not used this pref yet, so I can't tell you exactly how it's supposed to work, but it looks like GetPref(6755) returns returns FALSE if you are on a Design or Sheet Layer, and TRUE if you are inside a GROUP, a Symbol, a Polyline Profile, an Extrude, i.e., inside a container object – BUT – if you enter a GROUP that's inside a Symbol Definition, it returns FALSE. Not sure I understand this last part. And here if gets weirder, if you are inside a Group inside another Group inside a Symbol Def, it returns TRUE. It's Alice Through the Looking Glass trying to find Waldo.

 

This is all off the cuff, and doesn't answer anybody's question at the moment, so enjoy the rabbit hole, all ye who enter.

 

Raymond

Link to comment

Selector 7013 did the trick, and I certainly do like it.  Selector 6755 sounds interesting.  I usually drop in a Waldo locus and do GetParent to figure out where I am, but I think the inconsistency you've stumbled on is fascinating.

 

Thank you for finding the answer.  Just as a curiosity, what documentation did you find the answer in?  The SDK?

Link to comment

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...