- Posts: 92
- Thank you received: 0
LinuxCNC Features - a kind of NGCGUI
13 years 4 months ago #35287
by Nick
Replied by Nick on topic LinuxCNC Features - a kind of NGCGUI
New results 
I've made a hack to solve keypress problem. This hack handles keypress.
I had to make a hack for moving elements up and down because somebody (probably top level window) handles "cursor-moved" event... :huh:
Almost the last thing is drag and drop. It works in standalone mode, but after embedding into axis, right after drag is started somebody steels Focus from treeview - so it wont accept drag-drop event, or even drag-move (only drag-failed, which does not give any info about position of fail)
I've made a hack to solve keypress problem. This hack handles keypress.
Code:
keyname = gtk.gdk.keyval_name(event.keyval)
#self.treeview.emit("expand-collapse-cursor-row", True, True, False)
selection = self.treeview.get_selection()
(model, pathlist) = selection.get_selected_rows()
path = pathlist[0] if len(pathlist) > 0 else None
if keyname == "Up" :
if path :
rect = self.treeview.get_cell_area(path, self.col_value)
path = self.treeview.get_path_at_pos(rect[0],rect[1]-1)
if path :
path = path[0]
self.treeview.set_cursor(path, focus_column=self.col_value, start_editing=False)
return True
if keyname == "Down" :
if path :
rect = self.treeview.get_cell_area(path, self.col_value)
path = self.treeview.get_path_at_pos(rect[0],rect[1]+rect[3]+1)
if path :
path = path[0]
self.treeview.set_cursor(path, focus_column=self.col_value, start_editing=False)
return True
if keyname == "Left" :
if path!= None :
self.treeview.collapse_row(path)
return True
if keyname == "Right" :
if path!= None :
self.treeview.expand_row(path,False)
return True
if keyname == "Return" :
if path!= None :
iter = model.get_iter(path)
self.treeview.set_cursor_on_cell(path, focus_column=self.col_value, focus_cell=self.cell_value, start_editing=True)
return True
Almost the last thing is drag and drop. It works in standalone mode, but after embedding into axis, right after drag is started somebody steels Focus from treeview - so it wont accept drag-drop event, or even drag-move (only drag-failed, which does not give any info about position of fail)
Code:
<gtk.gdk.Event at 0x8cdb980: GDK_MOTION_NOTIFY x=115.00, y=16.00> <gtk.TreeView object at 0x8a66914 (GtkTreeView at 0x8abe1a8)>
<gtk.gdk.Event at 0x8cdb980: GDK_LEAVE_NOTIFY x=0.00, y=0.00, mode=GDK_CROSSING_GTK_GRAB> <gtk.TreeView object at 0x8a66914 (GtkTreeView at 0x8abe1a8)>
<gtk.gdk.Event at 0x8cdb980: GDK_LEAVE_NOTIFY x=0.00, y=0.00, mode=GDK_CROSSING_GTK_GRAB> <gtk.TreeView object at 0x8a66914 (GtkTreeView at 0x8abe1a8)>
<gtk.gdk.Event at 0x8cdb980: GDK_LEAVE_NOTIFY x=0.00, y=0.00, mode=GDK_CROSSING_GTK_GRAB> <gtk.TreeView object at 0x8a66914 (GtkTreeView at 0x8abe1a8)>
<gtk.gdk.Event at 0x8cdb980: GDK_GRAB_BROKEN> <gtk.TreeView object at 0x8a66914 (GtkTreeView at 0x8abe1a8)>
Please Log in to join the conversation.
13 years 4 months ago #35424
by Nick
Replied by Nick on topic LinuxCNC Features - possible replacement of NGCGUI
I've "solved" drag/drop problem by adding navigation buttons 
But it could be much easier to use drag/drop...
Features are almost ready for the first tests
But it could be much easier to use drag/drop...
Features are almost ready for the first tests
Please Log in to join the conversation.
13 years 4 months ago #35643
by Nick
Replied by Nick on topic LinuxCNC Features - possible replacement of NGCGUI
A lot of work have been done since last time and now we have Probing subroutines.
Including finding center of the hole, cube, finding tool's diameter. All subs are highly customisable.
Latest demo:
Unfortunately I do not have a working machine nearby righ now. It'll be awesome if somebody would be able to test it on the hardware.
PS Features now can run as a standalone application, dealing with axis throught axis-remote so it can be run-in-place without installing. just run
python features.py --ini=<path to your LinuxCNC ini file>.
Including finding center of the hole, cube, finding tool's diameter. All subs are highly customisable.
Latest demo:
Unfortunately I do not have a working machine nearby righ now. It'll be awesome if somebody would be able to test it on the hardware.
PS Features now can run as a standalone application, dealing with axis throught axis-remote so it can be run-in-place without installing. just run
python features.py --ini=<path to your LinuxCNC ini file>.
Please Log in to join the conversation.
13 years 4 months ago #35656
by andypugh
Replied by andypugh on topic LinuxCNC Features - possible replacement of NGCGUI
That looks great, though I have little idea what is going on
Please Log in to join the conversation.
13 years 4 months ago #35681
by Nick
Replied by Nick on topic LinuxCNC Features - possible replacement of NGCGUI
Haha 
You are right, probably I would not get anything from that video if I did not made it by myself
.
Here's a small tutorial showing features of LinuxCNC Features
.
PS sorry for my English, it leaves much to be desired.
You are right, probably I would not get anything from that video if I did not made it by myself
Here's a small tutorial showing features of LinuxCNC Features
PS sorry for my English, it leaves much to be desired.
Please Log in to join the conversation.
- Zahnrad Kopf
- Offline
- Senior Member
-
Less
More
- Posts: 55
- Thank you received: 0
13 years 4 months ago #35685
by Zahnrad Kopf
Replied by Zahnrad Kopf on topic LinuxCNC Features - possible replacement of NGCGUI
Nick, your English is fine and your skill is even better. And your contribution is appreciated by this newbie.
Please Log in to join the conversation.
13 years 4 months ago #35688
by Rick G
Did this fail to get attached?
Rick G
Replied by Rick G on topic LinuxCNC Features - possible replacement of NGCGUI
Here's a small tutorial showing features of LinuxCNC Features
Did this fail to get attached?
Rick G
Please Log in to join the conversation.
13 years 4 months ago #35689
by cmorley
Replied by cmorley on topic LinuxCNC Features - possible replacement of NGCGUI
It's there Rick.
Please Log in to join the conversation.
13 years 4 months ago #35696
by Nick
Replied by Nick on topic LinuxCNC Features - possible replacement of NGCGUI
Thinking further of Lathe subroutines...
I have no experience working with them...
Are there any standard subroutines for lathe machining?
What about multipass cutting?
Is there something like G71 that I've found in HAAS lathe manual in LinuxCNC?
I have no experience working with them...
Are there any standard subroutines for lathe machining?
What about multipass cutting?
Is there something like G71 that I've found in HAAS lathe manual in LinuxCNC?
Please Log in to join the conversation.
13 years 4 months ago #35697
by Rick G
John, Arceye and others have posted some great ones in the ngcgui section. Inside taper, Outside taper, Inside diameter, outside diameter. Multi pass. profile cutting etc.
In fact some of us use ngcgui for over 90% of what we do on a lathe.
Hey Chris,
I can see them now on my home office computer, but earlier today they did not show up on a work computer. Odd.
Probably because I do not have Flash player installed there.
Rick G
Replied by Rick G on topic LinuxCNC Features - possible replacement of NGCGUI
have no experience working with them...
Are there any standard subroutines for lathe machining?
What about multipass cutting?
Is there something like G71 that I've found in HAAS lathe manual in LinuxCNC?
John, Arceye and others have posted some great ones in the ngcgui section. Inside taper, Outside taper, Inside diameter, outside diameter. Multi pass. profile cutting etc.
In fact some of us use ngcgui for over 90% of what we do on a lathe.
Hey Chris,
I can see them now on my home office computer, but earlier today they did not show up on a work computer. Odd.
Probably because I do not have Flash player installed there.
Rick G
Please Log in to join the conversation.
Time to create page: 0.109 seconds
