Jump to content

Custom pump control


Sekel

Recommended Posts

Thanks for fast replies.

I found advice about pict_ring control while googling few days ago, but somehow Im unable to implement it. I created type def of pict_ring and added few pictures, but they do not show in. See snap photo below. 

Pic_ring_prob.png

Another problem is, that LabVIEW does not accept gifs in form I have posted here. You can try it by yourself if you are willing to, but message about error appears to me everytime Im trying to load one of the attached gifs as a picture (to standard OK button). 

And last problem of all, Its clickable control so far. One click makes it OFF (red), another makes it ON. How to solve this, If I use indicator instead of control?     

Edited by Sekel
Link to comment

Thanx a lot hooovahh, your solution works for me! Could you please teach me, how to do it? 

- I dont know, how to make transparent "transition states" of button control. For ON and OFF states its possible to set it in properties. For button transition states, I am lost.

- How did you add "shadowing" for transparent button.

-  Could this work also with picture ring indicator?  4 state picture ring indicator should be more logic for control (I could convert 2 bit boolean array to numer giving value to picture ring). Do you have any idea why is it not working with my pictures / gifs?

Once again, thanx a lot for your help!   

Link to comment
5 hours ago, Sekel said:

- I dont know, how to make transparent "transition states" of button control. For ON and OFF states its possible to set it in properties. For button transition states, I am lost.

I selected the Classic Square Button to start, and then using the painting tool colored the True, and the False values transparent.  This button has 4 states (not 6 like system buttons) and painting the two values made all 4 states transparent.  But you can just copy the button for yourself.

5 hours ago, Sekel said:

- How did you add "shadowing" for transparent button.

I didn't.  If you run the VI you see this shoadowing go away.  This is because this shadowing is not part of the UI and is only there to show that an object is on top of another object. You get the same effect if you move any control over top of a tab (not by dragging that places it in the tab)

5 hours ago, Sekel said:

-  Could this work also with picture ring indicator?  4 state picture ring indicator should be more logic for control (I could convert 2 bit boolean array to numer giving value to picture ring). Do you have any idea why is it not working with my pictures / gifs?

Picture rings, and 2D picture controls in general don't support gif, or alpha layer transparencies.  This is why I went with images on the front panel, it is the simplest solution.  Otherwise when you have a gif you need to have code running in a loop that will update the static images at regular intervals.  With this image that isn't too hard to do because there is a 400ms wait between changing the image but it still adds more logic, and if you only have these 4 states the code is quite simple.

Link to comment

I considered "static images" pict_ring as well. As you say - with 3 frame gif changing at 0,4s it is not a big deal. The truth is, I was unable to get rid of that nasty frame around. And frameless button/indicator is a must for my application. I finally found out, how to make "complete transparent" picture and checked the shadowing as you described it. Now I wonder how transparent tabs are made. I do not see any color property in the menu.  

Link to comment
1 hour ago, Sekel said:

I do not see any color property in the menu.  

I just painted the tab with the color brush transparent, starting with the classic tab.  Having a picture ring that you need to change the values of isn't a big deal, but it is more code that my solution didn't need.

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.

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.