Jump to content

Vector Boolean Creator


Recommended Posts

  • 3 months later...
Posted

What are some of your environment versions?  I've tested this on Windows 7 x64 LabVIEW 2015, 2016, 2017 32-bit, and with some success on Server 2012 x64 LabVIEW 2015.  I say some because it runs and works, but the preview images aren't shown in the selection UI.  Really that is just a terrible hacky solution and I regret doing it.  If I get some time I may try to revert back to the picture control solution.  You're issue definitely has to do with the .net stuff.

Posted

Oh the mysteries of .Net.  It seems Windows 10 comes with at least 4.6.  The code I developed is based on the link you provided, which is why I'm also confused why that works and mine doesn't.

  • 5 months later...
Posted (edited)

That is very nice, now I don't have to waste hours of time for this buttons :)

 

Edit, I have only one problem - for some images size of the generated control is 200KB or greater, for me this is fine but LV seems to have the problem and slow down significantly during edit time...

Edited by pawhan11
  • 5 years later...
  • 1 year later...
Posted
On 9/19/2024 at 2:09 AM, hooovahh said:

Because of a thread over on the darkside, I got the motivation to improve this code, and include the Google Material icons in it.  I posted the package over on VIPM.IO.  This uses the native 2D picture control for displaying icons like I wanted. It still requires Windows due to how icons are resized, but maybe that could be worked around if there is interest.

https://www.vipm.io/package/hooovahh_boolean_vector_controls/

Install the package and its dependencies and you'll have a Tools >> Hooovahh >> Boolean Control Creation...  Once ran it will start trying to display all the icons the toolkit installed.  In the background it will be converting the vector images to 56x56 PNGs to be able to display them in the window.  I tried being smart and having it prioritize icons that you scrolled to, but I honestly don't know how well it works.  It basically takes about a minute after first launching it to have all of its icons displayed properly.  You can use the tool during that minute but not all the icons will be available yet.  From that point on you can scroll around and resize the window and it should work as expected, just a little bit slow at times. There is a single constant on the block diagram where you can change the icon side. At one point I had icon size be a control on the front panel but since it took about a minute to process all the images for every change I just left it.

Some of the icons have multiple versions.  If you left click on an icon and a window pops up you can pick from what version of that icon you'd like to use.  Then create a control using that icon.  You can theoretically put your own EMF files in the folder with the rest but at the moment it doesn't scan for new files since it is relatively slow to find all icons on every launch.  What I'm saying is compromises had to be made.  Maybe I could have a separate program that gets ran in the Post Install VI that starts processing the icons right away in parallel.  That way the tool might be done processing icons by the time the user launches it for the first time.

I did use the Post Install and Post Uninstall to do extra work since there are so many individual files. Normally you'd have VIPM handle the files but it took a long time. So the package just installs a Zip, and the Post Install will unzip them. This also means Post Uninstall needs to delete the extracted files. Not ideal but the install time was much longer otherwise.

hooovahh,

I have a question: Is it possible to generate an application(exe in windows) that runs in a runtime environment only?

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  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...

Important Information

By using this site, you agree to our Terms of Use.