Hello Guest it is March 28, 2024, 05:06:33 AM

Author Topic: Mach4 screen GRAPHICS -- makin' it Purdy  (Read 38408 times)

0 Members and 1 Guest are viewing this topic.

Offline simpson36

*
  •  1,369 1,369
    • View Profile
Mach4 screen GRAPHICS -- makin' it Purdy
« on: March 09, 2015, 08:25:18 AM »
Now that Mach4 has image toggle buttons, I think its time to dedicate a thread to making the MACH4 screens attractive .  and of course intuitive and 'user friendly' at the same time.

Also a place to pester the developers for cool stuff and provide inspiration and incentive by demonstrating what can be done with the tools they provide.

The attached video is the part of the MACH screen where I put the InTurn™ 4th axis controls. For those who have not played with MACH4 screen mods, jump in! The stuff you see in the little attachment took only a couple of hours to do, including the scripts behind the buttons.

Just to show something a little different, I added a lighted rocker switch in place of one of the boring toggles. Pretty slick (if I do say so myself), however, I am thrarted in attempts to do some really cool stuff because I cannot find a way to get rid of the border around each button.

So two questions to start off.

1) can the borders be removed from buttons
2) what is Z order for? Seems to have no effect on anything


Offline ger21

*
  • *
  •  6,295 6,295
    • View Profile
    • The CNC Woodworker
Re: Mach4 screen GRAPHICS -- makin' it Purdy
« Reply #1 on: March 09, 2015, 09:42:22 AM »
While the Mach4 screen designer is very powerful, in some ways it's more limited than Mach3. I requested dual state LED's like mach3 uses about a year ago. This would let you do a lot of cool things.
I also requested more font options, but was told that they couldn't do it, because they someday will be making Mach4 cross platform, and couldn't support additional fonts. :-(

Z Order brings items to the front, or sends them to the back, but it's quirky it seems.
Gerry

2010 Screenset
http://www.thecncwoodworker.com/2010.html

JointCAM Dovetail and Box Joint software
http://www.g-forcecnc.com/jointcam.html

Offline simpson36

*
  •  1,369 1,369
    • View Profile
Re: Mach4 screen GRAPHICS -- makin' it Purdy
« Reply #2 on: March 09, 2015, 02:21:55 PM »
Can you explain 'dual state'?

There is provision for two scripts, so that is obviously not what you are looking for. The smoothness of curved lines (or circles) is not impressive, but that looks to me like an antialiasing issue.

Image toggles was just added literally a few days ago. Do you believe that he screen tools will not be improved from this point? To my eye, unlike MACH3, Mach4 seems to be getting a lot of attention and is coming along well, so I am optimistic.

I was speaking to one of the engineers at MachMotion today and they are very high on Mach4. That is one of many indicators that Mach4 will be a stable piece of software. Fingers still crossed, but so far so good, I would say.

In any case, I am having fun with the new screen goodies. FormBuilder gets pretty boring pretty quick.

Offline ger21

*
  • *
  •  6,295 6,295
    • View Profile
    • The CNC Woodworker
Re: Mach4 screen GRAPHICS -- makin' it Purdy
« Reply #3 on: March 09, 2015, 03:13:03 PM »
By dual state, I mean Image LED's that use one image for on, and one image for off. This allowed me to create checkboxes and radio buttons in Mach3.

Quote
Do you believe that he screen tools will not be improved from this point?

No. I just don't think that they're a priority right now.

Like you, I haven't really looked at Mach4 for the last 6 months. I'll start looking at it again soon.

I do see that it's definitely more stable than it was back then.

Gerry

2010 Screenset
http://www.thecncwoodworker.com/2010.html

JointCAM Dovetail and Box Joint software
http://www.g-forcecnc.com/jointcam.html

Offline simpson36

*
  •  1,369 1,369
    • View Profile
Re: Mach4 screen GRAPHICS -- makin' it Purdy
« Reply #4 on: March 09, 2015, 07:28:56 PM »
By dual state, I mean Image LED's that use one image for on, and one image for off. This allowed me to create checkboxes and radio buttons in Mach3.

Workarounds of course are never the first choice, but I'm thinking that checkboxes and radio buttons could be made from the image toggle buttons. They are a lot more versatile than the LEDs.

There are some number of scr.********* functions that can get and set properties of the screen controls. I do not know if these are documented officially anywhere, but I just fell over them in some scripts and used them in my controller screen. Pretty slick stuff.

Thus far I have only used toggle buttons and a couple of sliders, so I'm just scratching the surface at this point. I am inclined to want to avoid tools like FormBUilder and the Widget thing and just build my own library of doo-dads or maybe make the screens up in C# and just talk to them with Lua. Certainly there ar eplanty of libraries for dx and OpenGl. Not really sure yet. Just tinkering at this point.  :-\

I am just starting to tinker with a touch screen for my next gen of controllers and there is a graphics primitives library for that so if I go that rout it *might* be fairly simple to port over to any platform by swapping in equivalent functions. That would be the extreme optimistic viewpoint . . .  I should lie probably just down until that passes.  :D

Offline poppabear

*
  • *
  •  2,235 2,235
  • Briceville, TN, USA
    • View Profile
Re: Mach4 screen GRAPHICS -- makin' it Purdy
« Reply #5 on: March 10, 2015, 09:56:07 AM »
Steve,

      NICE!!! Love your toggle Pic/button It looks like a Rolls Royce emblem on a VW hood...... hehehehee
again, nice work!!!

What Graphics designer are you using for your pic's?

thanks for showing your work.

Scott

fun times

Offline poppabear

*
  • *
  •  2,235 2,235
  • Briceville, TN, USA
    • View Profile
Re: Mach4 screen GRAPHICS -- makin' it Purdy
« Reply #6 on: March 10, 2015, 01:15:18 PM »
fun times

Offline simpson36

*
  •  1,369 1,369
    • View Profile
Re: Mach4 screen GRAPHICS -- makin' it Purdy
« Reply #7 on: March 10, 2015, 05:38:32 PM »
The scr.********* functions do not work in all cases. At least not for me.

It will be a matter of experimentation to find which are useful . . .  unless somebody has already made a list.

For example, I cannot get the color to change on an LED. I have tried passing a string i.e. 'Red'  'Blue' etc. without success and also tried passing RGB values i.e. '(200,100,10)' also with no success.

I'll try hex values before giving up on that particular effort. LED's don't seem all that useful anyway.

Offline poppabear

*
  • *
  •  2,235 2,235
  • Briceville, TN, USA
    • View Profile
Re: Mach4 screen GRAPHICS -- makin' it Purdy
« Reply #8 on: March 10, 2015, 05:40:02 PM »
it is Hex values
fun times

Offline simpson36

*
  •  1,369 1,369
    • View Profile
Re: Mach4 screen GRAPHICS -- makin' it Purdy
« Reply #9 on: March 10, 2015, 06:09:16 PM »
it is Hex values

Tried this. NO success so far.

How do you put a hex value in a string field?

       scr.SetProperty('ledTEST', 'Color', '200');

       scr.SetProperty('ledTEST', 'Color', "Light");  Light is a var with an integer numeric value

       scr.SetProperty('ledTEST', 'Color', '0x60');
« Last Edit: March 10, 2015, 06:11:15 PM by simpson36 »