Commit 02656c96 authored by un's avatar un
Browse files

more removing tabs and conforming files to Miller's guidelines

parent 5c4fe5d5
#! /bin/sh
# Guess values for system-dependent variables and create Makefiles.
# Generated by GNU Autoconf 2.68 for pdflite 0.02-2.
# Generated by GNU Autoconf 2.69 for pdflite 0.02-2.
#
# Report bugs to <moocow@ling.uni-potsdam.de>.
#
#
# Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
# 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010 Free Software
# Foundation, Inc.
# Copyright (C) 1992-1996, 1998-2012 Free Software Foundation, Inc.
#
#
# This configure script is free software; the Free Software Foundation
......@@ -136,6 +134,31 @@ export LANGUAGE
# CDPATH.
(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
# Use a proper internal environment variable to ensure we don't fall
# into an infinite loop, continuously re-executing ourselves.
if test x"${_as_can_reexec}" != xno && test "x$CONFIG_SHELL" != x; then
_as_can_reexec=no; export _as_can_reexec;
# We cannot yet assume a decent shell, so we have to provide a
# neutralization value for shells without unset; and this also
# works around shells that cannot unset nonexistent variables.
# Preserve -v and -x to the replacement shell.
BASH_ENV=/dev/null
ENV=/dev/null
(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
case $- in # ((((
*v*x* | *x*v* ) as_opts=-vx ;;
*v* ) as_opts=-v ;;
*x* ) as_opts=-x ;;
* ) as_opts= ;;
esac
exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
# Admittedly, this is quite paranoid, since all the known shells bail
# out after a failed `exec'.
$as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2
as_fn_exit 255
fi
# We don't want this to propagate to other subprocesses.
{ _as_can_reexec=; unset _as_can_reexec;}
if test "x$CONFIG_SHELL" = x; then
as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then :
emulate sh
......@@ -169,7 +192,8 @@ if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then :
else
exitcode=1; echo positional parameters were not saved.
fi
test x\$exitcode = x0 || exit 1"
test x\$exitcode = x0 || exit 1
test -x / || exit 1"
as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO
as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO
eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" &&
......@@ -213,21 +237,25 @@ IFS=$as_save_IFS
if test "x$CONFIG_SHELL" != x; then :
# We cannot yet assume a decent shell, so we have to provide a
# neutralization value for shells without unset; and this also
# works around shells that cannot unset nonexistent variables.
# Preserve -v and -x to the replacement shell.
BASH_ENV=/dev/null
ENV=/dev/null
(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
export CONFIG_SHELL
case $- in # ((((
*v*x* | *x*v* ) as_opts=-vx ;;
*v* ) as_opts=-v ;;
*x* ) as_opts=-x ;;
* ) as_opts= ;;
esac
exec "$CONFIG_SHELL" $as_opts "$as_myself" ${1+"$@"}
export CONFIG_SHELL
# We cannot yet assume a decent shell, so we have to provide a
# neutralization value for shells without unset; and this also
# works around shells that cannot unset nonexistent variables.
# Preserve -v and -x to the replacement shell.
BASH_ENV=/dev/null
ENV=/dev/null
(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
case $- in # ((((
*v*x* | *x*v* ) as_opts=-vx ;;
*v* ) as_opts=-v ;;
*x* ) as_opts=-x ;;
* ) as_opts= ;;
esac
exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
# Admittedly, this is quite paranoid, since all the known shells bail
# out after a failed `exec'.
$as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2
exit 255
fi
if test x$as_have_required = xno; then :
......@@ -330,6 +358,14 @@ $as_echo X"$as_dir" |
} # as_fn_mkdir_p
# as_fn_executable_p FILE
# -----------------------
# Test if FILE is an executable regular file.
as_fn_executable_p ()
{
test -f "$1" && test -x "$1"
} # as_fn_executable_p
# as_fn_append VAR VALUE
# ----------------------
# Append the text in VALUE to the end of the definition contained in VAR. Take
......@@ -451,6 +487,10 @@ as_cr_alnum=$as_cr_Letters$as_cr_digits
chmod +x "$as_me.lineno" ||
{ $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; }
# If we had to re-execute with $CONFIG_SHELL, we're ensured to have
# already done that, so ensure we don't try to do so again and fall
# in an infinite loop. This has already happened in practice.
_as_can_reexec=no; export _as_can_reexec
# Don't try to exec as it changes $[0], causing all sort of problems
# (the dirname of $[0] is not the place where we might find the
# original and so on. Autoconf is especially sensitive to this).
......@@ -485,16 +525,16 @@ if (echo >conf$$.file) 2>/dev/null; then
# ... but there are two gotchas:
# 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
# 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
# In both cases, we have to default to `cp -p'.
# In both cases, we have to default to `cp -pR'.
ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
as_ln_s='cp -p'
as_ln_s='cp -pR'
elif ln conf$$.file conf$$ 2>/dev/null; then
as_ln_s=ln
else
as_ln_s='cp -p'
as_ln_s='cp -pR'
fi
else
as_ln_s='cp -p'
as_ln_s='cp -pR'
fi
rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
rmdir conf$$.dir 2>/dev/null
......@@ -506,28 +546,8 @@ else
as_mkdir_p=false
fi
if test -x / >/dev/null 2>&1; then
as_test_x='test -x'
else
if ls -dL / >/dev/null 2>&1; then
as_ls_L_option=L
else
as_ls_L_option=
fi
as_test_x='
eval sh -c '\''
if test -d "$1"; then
test -d "$1/.";
else
case $1 in #(
-*)set "./$1";;
esac;
case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #((
???[sx]*):;;*)false;;esac;fi
'\'' sh
'
fi
as_executable_p=$as_test_x
as_test_x='test -x'
as_executable_p=as_fn_executable_p
# Sed expression to map a string onto a valid CPP name.
as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
......@@ -1085,8 +1105,6 @@ target=$target_alias
if test "x$host_alias" != x; then
if test "x$build_alias" = x; then
cross_compiling=maybe
$as_echo "$as_me: WARNING: if you wanted to set the --build type, don't use --host.
If a cross compiler is detected then cross compile mode will be used" >&2
elif test "x$build_alias" != "x$host_alias"; then
cross_compiling=yes
fi
......@@ -1318,9 +1336,9 @@ test -n "$ac_init_help" && exit $ac_status
if $ac_init_version; then
cat <<\_ACEOF
pdflite configure 0.02-2
generated by GNU Autoconf 2.68
generated by GNU Autoconf 2.69
Copyright (C) 2010 Free Software Foundation, Inc.
Copyright (C) 2012 Free Software Foundation, Inc.
This configure script is free software; the Free Software Foundation
gives unlimited permission to copy, distribute and modify it.
_ACEOF
......@@ -1427,7 +1445,7 @@ $as_echo "$ac_try_echo"; } >&5
test ! -s conftest.err
} && test -s conftest$ac_exeext && {
test "$cross_compiling" = yes ||
$as_test_x conftest$ac_exeext
test -x conftest$ac_exeext
}; then :
ac_retval=0
else
......@@ -1450,7 +1468,7 @@ This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake.
It was created by pdflite $as_me 0.02-2, which was
generated by GNU Autoconf 2.68. Invocation command line was
generated by GNU Autoconf 2.69. Invocation command line was
$ $0 $@
......@@ -1888,7 +1906,7 @@ do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
for ac_exec_ext in '' $ac_executable_extensions; do
if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
ac_cv_prog_CC="${ac_tool_prefix}gcc"
$as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
......@@ -1928,7 +1946,7 @@ do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
for ac_exec_ext in '' $ac_executable_extensions; do
if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
ac_cv_prog_ac_ct_CC="gcc"
$as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
......@@ -1981,7 +1999,7 @@ do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
for ac_exec_ext in '' $ac_executable_extensions; do
if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
ac_cv_prog_CC="${ac_tool_prefix}cc"
$as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
......@@ -2022,7 +2040,7 @@ do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
for ac_exec_ext in '' $ac_executable_extensions; do
if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
ac_prog_rejected=yes
continue
......@@ -2080,7 +2098,7 @@ do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
for ac_exec_ext in '' $ac_executable_extensions; do
if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
$as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
......@@ -2124,7 +2142,7 @@ do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
for ac_exec_ext in '' $ac_executable_extensions; do
if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
ac_cv_prog_ac_ct_CC="$ac_prog"
$as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
......@@ -2570,8 +2588,7 @@ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
#include <stdarg.h>
#include <stdio.h>
#include <sys/types.h>
#include <sys/stat.h>
struct stat;
/* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
struct buf { int x; };
FILE * (*rcsopen) (struct buf *, struct stat *, int);
......@@ -3408,16 +3425,16 @@ if (echo >conf$$.file) 2>/dev/null; then
# ... but there are two gotchas:
# 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
# 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
# In both cases, we have to default to `cp -p'.
# In both cases, we have to default to `cp -pR'.
ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
as_ln_s='cp -p'
as_ln_s='cp -pR'
elif ln conf$$.file conf$$ 2>/dev/null; then
as_ln_s=ln
else
as_ln_s='cp -p'
as_ln_s='cp -pR'
fi
else
as_ln_s='cp -p'
as_ln_s='cp -pR'
fi
rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
rmdir conf$$.dir 2>/dev/null
......@@ -3477,28 +3494,16 @@ else
as_mkdir_p=false
fi
if test -x / >/dev/null 2>&1; then
as_test_x='test -x'
else
if ls -dL / >/dev/null 2>&1; then
as_ls_L_option=L
else
as_ls_L_option=
fi
as_test_x='
eval sh -c '\''
if test -d "$1"; then
test -d "$1/.";
else
case $1 in #(
-*)set "./$1";;
esac;
case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #((
???[sx]*):;;*)false;;esac;fi
'\'' sh
'
fi
as_executable_p=$as_test_x
# as_fn_executable_p FILE
# -----------------------
# Test if FILE is an executable regular file.
as_fn_executable_p ()
{
test -f "$1" && test -x "$1"
} # as_fn_executable_p
as_test_x='test -x'
as_executable_p=as_fn_executable_p
# Sed expression to map a string onto a valid CPP name.
as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
......@@ -3520,7 +3525,7 @@ cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
# values after options handling.
ac_log="
This file was extended by pdflite $as_me 0.02-2, which was
generated by GNU Autoconf 2.68. Invocation command line was
generated by GNU Autoconf 2.69. Invocation command line was
CONFIG_FILES = $CONFIG_FILES
CONFIG_HEADERS = $CONFIG_HEADERS
......@@ -3573,10 +3578,10 @@ cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
ac_cs_version="\\
pdflite config.status 0.02-2
configured by $0, generated by GNU Autoconf 2.68,
configured by $0, generated by GNU Autoconf 2.69,
with options \\"\$ac_cs_config\\"
Copyright (C) 2010 Free Software Foundation, Inc.
Copyright (C) 2012 Free Software Foundation, Inc.
This config.status script is free software; the Free Software Foundation
gives unlimited permission to copy, distribute and modify it."
......@@ -3653,7 +3658,7 @@ fi
_ACEOF
cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
if \$ac_cs_recheck; then
set X '$SHELL' '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
shift
\$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
CONFIG_SHELL='$SHELL'
......
......@@ -83,7 +83,7 @@
/* #undef HAVE_LIBTCL8_4 */
/* Define to 1 if you have the `tcl8.5' library (-ltcl8.5). */
#define HAVE_LIBTCL8_5 1
/* #undef HAVE_LIBTCL8_5 */
/* Define to 1 if you have the `tk84' library (-ltk84). */
/* #undef HAVE_LIBTK84 */
......@@ -104,7 +104,7 @@
/* #undef HAVE_LIBTK8_4 */
/* Define to 1 if you have the `tk8.5' library (-ltk8.5). */
#define HAVE_LIBTK8_5 1
/* #undef HAVE_LIBTK8_5 */
/* Define to 1 if you have the <limits.h> header file. */
#define HAVE_LIMITS_H 1
......@@ -211,7 +211,7 @@
#define TIME_WITH_SYS_TIME 1
/* Number of bits in a file offset, on hosts where this is settable. */
/* #undef _FILE_OFFSET_BITS */
#define _FILE_OFFSET_BITS 64
/* Define for large files, on AIX-style hosts. */
/* #undef _LARGE_FILES */
......
......@@ -225,7 +225,7 @@ int template_has_elemtemplate(t_template *t, t_template *elemtemplate)
if (t && elemtemplate)
{
int i;
t_dataslot *d = t->t_vec;
t_dataslot *d = t->t_vec;
for (i = 0; i < t->t_n; i++, d++)
{
if (d->ds_type == DT_ARRAY)
......@@ -281,11 +281,11 @@ static void scalar_getgrouprect(t_glist *owner, t_glist *groupcanvas,
for (y = groupcanvas->gl_list; y; y = y->g_next)
{
if (pd_class(&y->g_pd) == canvas_class &&
((t_canvas *)y)->gl_svg)
((t_canvas *)y)->gl_svg)
{
/* todo: accumulate basex and basey for correct offset */
scalar_getgrouprect(owner, (t_glist *)y, data, template,
basex, basey, x1, x2, y1, y2);
basex, basey, x1, x2, y1, y2);
}
else
{
......@@ -351,8 +351,8 @@ static void scalar_getrect(t_gobj *z, t_glist *owner,
x1 = y1 = 0x7fffffff;
x2 = y2 = -0x7fffffff;
scalar_getgrouprect(owner, templatecanvas, x->sc_vec, template,
basex, basey, &x1, &x2, &y1, &y2);
if (x2 < x1 || y2 < y1)
basex, basey, &x1, &x2, &y1, &y2);
if (x2 < x1 || y2 < y1)
x1 = y1 = x2 = y2 = 0;
}
}
......@@ -679,9 +679,9 @@ static void scalar_groupvis(t_scalar *x, t_glist *owner, t_template *template,
for (y = gl->gl_list; y; y = y->g_next)
{
if (pd_class(&y->g_pd) == canvas_class &&
((t_glist *)y)->gl_svg)
((t_glist *)y)->gl_svg)
{
scalar_groupvis(x, owner, template, (t_glist *)y, gl, vis);
scalar_groupvis(x, owner, template, (t_glist *)y, gl, vis);
}
t_parentwidgetbehavior *wb = pd_getparentwidget(&y->g_pd);
if (!wb) continue;
......@@ -772,12 +772,14 @@ static void scalar_vis(t_gobj *z, t_glist *owner, int vis)
t_parentwidgetbehavior *wb = pd_getparentwidget(&y->g_pd);
if (!wb)
{
/* check subpatches for more drawing commands. This
/* check subpatches for more drawing commands. This
can be optimized to only search [group] subpatches */
if (pd_class(&y->g_pd) == canvas_class &&
((t_glist *)y)->gl_svg)
((t_glist *)y)->gl_svg)
{
scalar_groupvis(x, owner, template,
(t_glist *)y, templatecanvas, vis);
}
continue;
}
(*wb->w_parentvisfn)(y, owner, 0, x, x->sc_vec, template,
......
......@@ -1752,7 +1752,7 @@ void svg_stroke(t_svg *x, t_symbol *s, t_int argc, t_atom *argv)
else if (argc > 2)
{
int var = 0, i;
t_fielddesc *fd = x->x_stroke;
t_fielddesc *fd = x->x_stroke;
for(i = 0; i < argc; i++)
var = (argv[i].a_type == A_SYMBOL) ? 1 : var;
if (var)
......@@ -2204,7 +2204,7 @@ void svg_group_pathrect_cache(t_svg *x, int state)
if (pd_class(&y->g_pd) == draw_class)
{
t_svg *a = (t_svg *)(((t_draw *)y)->x_attr);
if (a->x_pathrect_cache != -1)
if (a->x_pathrect_cache != -1)
a->x_pathrect_cache = state;
}
}
......@@ -4491,7 +4491,7 @@ static void plot_getgrouprect(t_glist *glist, t_template *elemtemplate,
int *x1, int *y1, int *x2, int *y2)
{
t_gobj *y;
for (y = groupcanvas->gl_list; y; y = y->g_next)
for (y = groupcanvas->gl_list; y; y = y->g_next)
{
if (pd_class(&y->g_pd) == canvas_class &&
((t_canvas *)y)->gl_svg)
......
......@@ -3,8 +3,9 @@
#include <stdio.h>
#include "g_undo.h"
//used for canvas_objtext to differentiate between objects being created by user
//vs. those (re)created by the undo/redo actions
/* used for canvas_objtext to differentiate between objects being created
by user vs. those (re)created by the undo/redo actions */
int we_are_undoing = 0;
extern const char *canvas_undo_name;
......@@ -12,203 +13,219 @@ extern void glob_preset_node_list_seek_hub(void);
t_undo_action *canvas_undo_init(t_canvas *x)
{
t_undo_action *a = (t_undo_action *)getbytes(sizeof(*a));
t_undo_action *a = (t_undo_action *)getbytes(sizeof(*a));
a->type = 0;
a->x = x;
a->next = NULL;
a->type = 0;
a->x = x;
a->next = NULL;
if (!x->u_queue) {
//this is the first init
x->u_queue = a;
x->u_last = a;
a->prev = NULL;
a->name = "no";
if (!x->u_queue)
{
//this is the first init
x->u_queue = a;
x->u_last = a;
a->prev = NULL;
a->name = "no";
sys_vgui("pdtk_undomenu .x%lx no no\n", (t_int)a->x);
}
else {
if (x->u_last->next) {
//we need to rebranch first then add the new action
canvas_undo_rebranch(x);
}
x->u_last->next = a;
a->prev = x->u_last;
x->u_last = a;
}
//fprintf(stderr,"canvas_undo_init\n");
return(a);
}
else
{
if (x->u_last->next)
{
//we need to rebranch first then add the new action
canvas_undo_rebranch(x);
}
x->u_last->next = a;
a->prev = x->u_last;
x->u_last = a;
}
//fprintf(stderr,"canvas_undo_init\n");
return(a);
}
t_undo_action *canvas_undo_add(t_canvas *x, int type, const char *name, void *data)
t_undo_action *canvas_undo_add(t_canvas *x, int type, const char *name,
void *data)
{
//fprintf(stderr,"canvas_undo_add %d\n", type);
t_undo_action *a = canvas_undo_init(x);
a->type = type;
a->data = (void *)data;
a->name = (char *)name;
canvas_undo_name = name;
//fprintf(stderr,"canvas_undo_add %d\n", type);
t_undo_action *a = canvas_undo_init(x);
a->type = type;
a->data = (void *)data;
a->name = (char *)name;
canvas_undo_name = name;
sys_vgui("pdtk_undomenu .x%lx %s no\n", x, a->name);
return(a);
return(a);
}
void canvas_undo_undo(t_canvas *x)
{
int dspwas = canvas_suspend_dsp();
if (x->u_queue && x->u_last != x->u_queue) {
we_are_undoing = 1;
//fprintf(stderr,"canvas_undo_undo %d\n", x->u_last->type);
glist_noselect(x);
canvas_undo_name = x->u_last->name;
int dspwas = canvas_suspend_dsp();
if (x->u_queue && x->u_last != x->u_queue)
{
we_are_undoing = 1;
//fprintf(stderr,"canvas_undo_undo %d\n", x->u_last->type);
glist_noselect(x);
canvas_undo_name = x->u_last->name;
switch(x->u_last->type)
{
case 1: canvas_undo_connect(x, x->u_last->data, UNDO_UNDO); break; //connect
case 2: canvas_undo_disconnect(x, x->u_last->data, UNDO_UNDO); break; //disconnect
case 3: canvas_undo_cut(x, x->u_last->data, UNDO_UNDO); break; //cut
case 4: canvas_undo_move(x, x->u_last->data, UNDO_UNDO); break; //move
case 5: canvas_undo_paste(x, x->u_last->data, UNDO_UNDO); break; //paste
case 6: canvas_undo_apply(x, x->u_last->data, UNDO_UNDO); break; //apply
case 7: canvas_undo_arrange(x, x->u_last->data, UNDO_UNDO); break; //arrange
case 8: canvas_undo_canvas_apply(x, x->u_last->data, UNDO_UNDO); break; //canvas apply
case 9: canvas_undo_create(x, x->u_last->data, UNDO_UNDO); break; //create
case 10:canvas_undo_recreate(x, x->u_last->data, UNDO_UNDO); break; //recreate
case 11:canvas_undo_font(x, x->u_last->data, UNDO_UNDO); break; //font
default:
error("canvas_undo_undo: unsupported undo command %d", x->u_last->type);
case 1: canvas_undo_connect(x, x->u_last->data, UNDO_UNDO); break; //connect
case 2: canvas_undo_disconnect(x, x->u_last->data, UNDO_UNDO); break; //disconnect
case 3: canvas_undo_cut(x, x->u_last->data, UNDO_UNDO); break; //cut
case 4: canvas_undo_move(x, x->u_last->data, UNDO_UNDO); break; //move
case 5: canvas_undo_paste(x, x->u_last->data, UNDO_UNDO); break; //paste
case 6: canvas_undo_apply(x, x->u_last->data, UNDO_UNDO); break; //apply
case 7: canvas_undo_arrange(x, x->u_last->data, UNDO_UNDO); break; //arrange
case 8: canvas_undo_canvas_apply(x, x->u_last->data, UNDO_UNDO); break; //canvas apply
case 9: canvas_undo_create(x, x->u_last->data, UNDO_UNDO); break; //create
case 10:canvas_undo_recreate(x, x->u_last->data, UNDO_UNDO); break; //recreate
case 11:canvas_undo_font(x, x->u_last->data, UNDO_UNDO); break; //font
default:
error("canvas_undo_undo: unsupported undo command %d", x->u_last->type);
}
x->u_last = x->u_last->prev;
char *undo_action = x->u_last->name;
char *redo_action = x->u_last->next->name;
we_are_undoing = 0;
// here we call updating of all unpaired hubs and nodes since their regular call
// will fail in case their position needed to be updated by undo/redo first to
// reflect the old one