1
0
mirror of git://projects.qi-hardware.com/cae-tools.git synced 2025-04-21 12:27:27 +03:00

The bottom face can now be shifted and rotated as well.

- solidify/overlap.h, solidify/overlap.c (edit_top, overlap_edit): select
  the face to rotate and shift
- solidify/overlap.c (scroll_event): select face to manipulate based on
  edit_top
- solidify/solidify.c (a_b, gui_buttons): new button B+A to select the
  bottom face for editing
- solidify/solidify.c clicked): call overlap_edit to select face to edit
This commit is contained in:
Werner Almesberger
2010-09-28 22:03:02 -03:00
parent 5fd9b33e5a
commit 733332da8c
3 changed files with 26 additions and 6 deletions

View File

@@ -28,13 +28,16 @@
static struct project *prj;
static const struct face *active; /* NULL if overlapping */
static GtkWidget *canvas;
static GtkWidget *canvas, *a_b;
static void clicked(GtkButton *button, gpointer user_data)
{
struct face *face = user_data;
if (!face)
overlap_edit(button == GTK_BUTTON(a_b));
if (active == face)
return;
@@ -66,7 +69,12 @@ static GtkWidget *gui_buttons(void)
g_signal_connect(G_OBJECT(but), "clicked",
G_CALLBACK(clicked), prj->s.b);
but = gtk_button_new_with_label("A+B");
a_b = gtk_button_new_with_label("A+B");
gtk_box_pack_start(GTK_BOX(vbox), a_b, FALSE, FALSE, 0);
g_signal_connect(G_OBJECT(a_b), "clicked",
G_CALLBACK(clicked), NULL);
but = gtk_button_new_with_label("B+A");
gtk_box_pack_start(GTK_BOX(vbox), but, FALSE, FALSE, 0);
g_signal_connect(G_OBJECT(but), "clicked",
G_CALLBACK(clicked), NULL);