- Posts: 6803
- Thank you received: 0
Сustomization QTvcp
5 years 10 months ago #191783
by cmorley
Replied by cmorley on topic Сustomization QTvcp
it does if you test the calculator directly.
I would guess that the font size gets overwritten from a stylesheet setting.
try something like:
I would guess that the font size gets overwritten from a stylesheet setting.
try something like:
Code:
Calculator QLineEdit{
font: 25pt "Lato Heavy";
}
Please Log in to join the conversation.
5 years 10 months ago #191813
by hottabich
Replied by hottabich on topic Сustomization QTvcp
Super!!! Works great! Now the calculator can be edited to your liking. I also added
Respect and respect for you.
Thank you!
Code:
Calculator QPushButton{
font: 13pt "Lato Heavy";
}
Thank you!
Please Log in to join the conversation.
5 years 10 months ago #192253
by hottabich
Replied by hottabich on topic Сustomization QTvcp
Clicked action button spindle_up_action or spindle_down_action, start spindle, start fwd or revers. I think it's wrong. Your comment please.
Please Log in to join the conversation.
5 years 10 months ago #192261
by cmorley
Replied by cmorley on topic Сustomization QTvcp
That is how it's designed.
If the spindle is not running it starts, if it's running it changes speed.
Of course you could code the button to do something else
Chris
If the spindle is not running it starts, if it's running it changes speed.
Of course you could code the button to do something else
Chris
Please Log in to join the conversation.
5 years 10 months ago #192269
by hottabich
Replied by hottabich on topic Сustomization QTvcp
Thank you, I see!
Please Log in to join the conversation.
5 years 10 months ago #192279
by cmorley
Replied by cmorley on topic Сustomization QTvcp
as it is now:
CCW always sets speed down, if the spindle is already running and CW always sets the speed up, if the spindle is already running.
I could see the argument for the button that starts the spindle always being the speed up button.
Chris
CCW always sets speed down, if the spindle is already running and CW always sets the speed up, if the spindle is already running.
I could see the argument for the button that starts the spindle always being the speed up button.
Chris
Please Log in to join the conversation.
5 years 10 months ago #192342
by hottabich
Replied by hottabich on topic Сustomization QTvcp
And please tell me how to programmatically disable the run in action button UP, Down function? This is for the safety of the car, I think so. Thanks for attention!
Please Log in to join the conversation.
5 years 10 months ago #192355
by cmorley
Replied by cmorley on topic Сustomization QTvcp
So this is the relevant code in action_button.py
it checks what spindle you wish to start (-1 means all spindles)
If the spindle is running it speeds them up.
If the spindle isn't running it starts it at the default spindle speed.
Here might be a function to add to the handler file to be called from a button.
You would need to use designer to connect a signal to it.
It assumes you only wish to speed up the spindle number 0
Chris
it checks what spindle you wish to start (-1 means all spindles)
If the spindle is running it speeds them up.
If the spindle isn't running it starts it at the default spindle speed.
Code:
elif self.spindle_up:
if self.joint == -1:
a = 0
b = INFO.AVAILABLE_SPINDLES
else:
a = self.joint
b = self.joint +1
for i in range(a,b):
if STATUS.is_spindle_on(i):
ACTION.SET_SPINDLE_FASTER(i)
else:
ACTION.SET_SPINDLE_ROTATION(linuxcnc.SPINDLE_FORWARD,
INFO['DEFAULT_SPINDLE_{}_SPEED'.format(i)],i)
Here might be a function to add to the handler file to be called from a button.
You would need to use designer to connect a signal to it.
It assumes you only wish to speed up the spindle number 0
Code:
def spindle_faster(self, state):
if state:
if STATUS.is_spindle_on(i):
ACTION.SET_SPINDLE_FASTER(0)
Chris
Please Log in to join the conversation.
5 years 10 months ago #192389
by hottabich
Replied by hottabich on topic Сustomization QTvcp
Did as in the screenshot did not change. What am I doing wrong?
Please Log in to join the conversation.
5 years 10 months ago #192406
by cmorley
Replied by cmorley on topic Сustomization QTvcp
Did you remove all builtin actions from the action button?
This new function should used instead of any qtvcp built in actions.
In fact it could be called from a normal QPushButton.
I would also add a temporary print statement to confirm if the new function is being called.
This new function should used instead of any qtvcp built in actions.
In fact it could be called from a normal QPushButton.
I would also add a temporary print statement to confirm if the new function is being called.
Please Log in to join the conversation.
Time to create page: 0.211 seconds
