From: Konstantin Dmitriev Date: Thu, 16 Jul 2009 13:21:26 +0000 (+0700) Subject: Merge branch 'master' into zelgadis_master X-Git-Url: https://git.pterodactylus.net/?a=commitdiff_plain;h=e9a42a585dec26a8c0aabcfd6e12755f0f0f1156;hp=62c72bf0bc6482003ae7423ecf727b2576fd5c46;p=synfig.git Merge branch 'master' into zelgadis_master --- diff --git a/.gitignore b/.gitignore index b43aba7..36dc72b 100644 --- a/.gitignore +++ b/.gitignore @@ -24,16 +24,30 @@ synfig-studio/src # ------------------------------------------------------------------------ # generated in ETL, core and studio +*-config +ABOUT-NLS +Makefile.in.in +Makevars.template +POTFILES +Rules-quot aclocal.m4 +autom4te.cache +boldquot.sed config.* configure -*-config depcomp +en@boldquot.header +en@quot.header +insert-header.sin install-sh libtool ltmain.sh missing +quot.sed +remove-potcdate.sed +remove-potcdate.sin stamp-h1 +stamp-po # ------------------------------------------------------------------------ @@ -43,18 +57,95 @@ ETL/trunk/ETL/etl_profile_.h synfig-core/trunk/libltdl synfig-core/trunk/pkg-info/macosx/synfig-core.info +synfig-core/trunk/po/*.gmo +synfig-core/trunk/po/synfig.pot synfig-core/trunk/src/modules/synfig_modules.cfg synfig-core/trunk/src/synfig/proto/nodebase.h synfig-core/trunk/src/tool/synfig synfig-core/trunk/synfig.pc.in +synfig-core/trunk/m4/codeset.m4 +synfig-core/trunk/m4/gettext.m4 +synfig-core/trunk/m4/glibc2.m4 +synfig-core/trunk/m4/glibc21.m4 +synfig-core/trunk/m4/iconv.m4 +synfig-core/trunk/m4/intdiv0.m4 +synfig-core/trunk/m4/inttypes.m4 +synfig-core/trunk/m4/inttypes-h.m4 +synfig-core/trunk/m4/inttypes_h.m4 +synfig-core/trunk/m4/inttypes-pri.m4 +synfig-core/trunk/m4/intmax.m4 +synfig-core/trunk/m4/isc-posix.m4 +synfig-core/trunk/m4/lcmessage.m4 +synfig-core/trunk/m4/lib-ld.m4 +synfig-core/trunk/m4/lib-link.m4 +synfig-core/trunk/m4/lib-prefix.m4 +synfig-core/trunk/m4/lock.m4 +synfig-core/trunk/m4/longdouble.m4 +synfig-core/trunk/m4/longlong.m4 +synfig-core/trunk/m4/po.m4 +synfig-core/trunk/m4/progtest.m4 +synfig-core/trunk/m4/nls.m4 +synfig-core/trunk/m4/printf-posix.m4 +synfig-core/trunk/m4/uintmax_t.m4 +synfig-core/trunk/m4/ulonglong.m4 +synfig-core/trunk/m4/signed.m4 +synfig-core/trunk/m4/size_max.m4 +synfig-core/trunk/m4/stdint_h.m4 +synfig-core/trunk/m4/visibility.m4 +synfig-core/trunk/m4/wchar_t.m4 +synfig-core/trunk/m4/wint_t.m4 +synfig-core/trunk/m4/xsize.m4 + +synfig-studio/trunk/autorevision.h +synfig-studio/trunk/images/128x128 +synfig-studio/trunk/images/16x16 +synfig-studio/trunk/images/22x22 +synfig-studio/trunk/images/24x24 +synfig-studio/trunk/images/32x32 +synfig-studio/trunk/images/48x48 +synfig-studio/trunk/images/64x64 +synfig-studio/trunk/images/*.png +synfig-studio/trunk/images/images.nsh +synfig-studio/trunk/images/unimages.nsh +synfig-studio/trunk/m4/codeset.m4 +synfig-studio/trunk/m4/gettext.m4 +synfig-studio/trunk/m4/glibc21.m4 +synfig-studio/trunk/m4/glibc2.m4 +synfig-studio/trunk/m4/iconv.m4 +synfig-studio/trunk/m4/intdiv0.m4 +synfig-studio/trunk/m4/intmax.m4 +synfig-studio/trunk/m4/inttypes-h.m4 +synfig-studio/trunk/m4/inttypes_h.m4 +synfig-studio/trunk/m4/inttypes.m4 +synfig-studio/trunk/m4/inttypes-pri.m4 +synfig-studio/trunk/m4/isc-posix.m4 +synfig-studio/trunk/m4/lcmessage.m4 +synfig-studio/trunk/m4/lib-ld.m4 +synfig-studio/trunk/m4/lib-link.m4 +synfig-studio/trunk/m4/lib-prefix.m4 +synfig-studio/trunk/m4/lock.m4 +synfig-studio/trunk/m4/longdouble.m4 +synfig-studio/trunk/m4/longlong.m4 +synfig-studio/trunk/m4/nls.m4 +synfig-studio/trunk/m4/po.m4 +synfig-studio/trunk/m4/printf-posix.m4 +synfig-studio/trunk/m4/progtest.m4 +synfig-studio/trunk/m4/signed.m4 +synfig-studio/trunk/m4/size_max.m4 +synfig-studio/trunk/m4/stdint_h.m4 +synfig-studio/trunk/m4/uintmax_t.m4 +synfig-studio/trunk/m4/ulonglong.m4 +synfig-studio/trunk/m4/visibility.m4 +synfig-studio/trunk/m4/wchar_t.m4 +synfig-studio/trunk/m4/wint_t.m4 +synfig-studio/trunk/m4/xsize.m4 synfig-studio/trunk/pkg-info/macosx/synfig-studio.info +synfig-studio/trunk/po/*.gmo +synfig-studio/trunk/po/synfigstudio.pot synfig-studio/trunk/src/gtkmm/synfigstudio synfig-studio/trunk/synfigstudio-thumbnailer.schemas synfig-studio/trunk/synfigstudio.desktop -synfig-studio/trunk/images/*.png -synfig-studio/trunk/images/images.nsh -synfig-studio/trunk/images/unimages.nsh # ------------------------------------------------------------------------ diff --git a/ETL/trunk/ETL.pbproj/etl_profile.h b/ETL/trunk/ETL.pbproj/etl_profile.h index 8d1b845..e63e0fe 100644 --- a/ETL/trunk/ETL.pbproj/etl_profile.h +++ b/ETL/trunk/ETL.pbproj/etl_profile.h @@ -8,32 +8,32 @@ /* define if target is big endian */ #define WORDS_BIGENDIAN -#ifndef __ETL_HAS_GETTIMEOFDAY -#define __ETL_HAS_GETTIMEOFDAY +#ifndef HAVE_GETTIMEOFDAY +#define HAVE_GETTIMEOFDAY #endif -#ifndef __ETL_HAS_PTHREAD_H -#define __ETL_HAS_PTHREAD_H +#ifndef HAVE_PTHREAD_H +#define HAVE_PTHREAD_H #endif -#ifndef __ETL_HAS_SCHED_H -#define __ETL_HAS_SCHED_H +#ifndef HAVE_SCHED_H +#define HAVE_SCHED_H #endif -#ifndef __ETL_HAS_PTHREAD_CREATE -#define __ETL_HAS_PTHREAD_CREATE +#ifndef HAVE_PTHREAD_CREATE +#define HAVE_PTHREAD_CREATE #endif -#ifndef __ETL_HAS_VASPRINTF -#define __ETL_HAS_VASPRINTF +#ifndef HAVE_VASPRINTF +#define HAVE_VASPRINTF #endif -#ifndef __ETL_HAS_VSNPRINTF -#define __ETL_HAS_VSNPRINTF +#ifndef HAVE_VSNPRINTF +#define HAVE_VSNPRINTF #endif -#ifndef __ETL_HAS_VSPRINTF -#define __ETL_HAS_VSPRINTF +#ifndef HAVE_VSPRINTF +#define HAVE_VSPRINTF #endif #endif // __VETL_CONFIG_H diff --git a/ETL/trunk/ETL.pc.in b/ETL/trunk/ETL.pc.in index 4417485..93c32bf 100644 --- a/ETL/trunk/ETL.pc.in +++ b/ETL/trunk/ETL.pc.in @@ -8,4 +8,4 @@ Description: @PACKAGE_NAME@ Requires: Version: @VERSION@ Libs: @LIBS@ -Cflags: -I${includedir} -I${libdir}/ETL/include +Cflags: -I${includedir} diff --git a/ETL/trunk/ETL/Makefile.am b/ETL/trunk/ETL/Makefile.am index ffa8f64..b08fdcf 100644 --- a/ETL/trunk/ETL/Makefile.am +++ b/ETL/trunk/ETL/Makefile.am @@ -3,10 +3,9 @@ MAINTAINERCLEANFILES = \ Makefile.in +CLEANFILES = \ + $(top_builddir)/ETL/etl_profile.h -etlconfigdir = $(libdir)/ETL/include - -etlconfig_DATA = etl_profile.h etldir = $(includedir)/ETL @@ -56,6 +55,7 @@ etl_HEADERS = \ _trivial.h \ _fixed.h \ etl_config.h \ + $(top_builddir)/ETL/etl_profile.h \ _fastangle_tables.h \ bezier \ _bezier.h \ @@ -77,6 +77,10 @@ etl_HEADERS = \ _mutex_pthreads_simple.h +$(top_builddir)/ETL/etl_profile.h:$(top_builddir)/ETL/etl_profile_.h + sed "s/PACKAGE/ETL/g;" < $(top_builddir)/ETL/etl_profile_.h > $(top_builddir)/ETL/etl_profile.h + + # FIXME: figure out why this is in SVN, but isn't installed EXTRA_DIST = \ _bit_rotate.h diff --git a/ETL/trunk/ETL/_mutex_pthreads.h b/ETL/trunk/ETL/_mutex_pthreads.h index 8720617..aed6766 100644 --- a/ETL/trunk/ETL/_mutex_pthreads.h +++ b/ETL/trunk/ETL/_mutex_pthreads.h @@ -33,7 +33,7 @@ #include -#ifdef __ETL_HAS_SCHED_H +#ifdef HAVE_SCHED_H # include #endif diff --git a/ETL/trunk/ETL/_stringf.h b/ETL/trunk/ETL/_stringf.h index 22939a2..3d0c020 100644 --- a/ETL/trunk/ETL/_stringf.h +++ b/ETL/trunk/ETL/_stringf.h @@ -53,13 +53,6 @@ #define POPEN_BINARY_WRITE_TYPE "w" #endif -#ifdef __ETL_HAS__VSNPRINTF -#ifndef __ETL_HAS_VSNPRINTF -#define vnsprintf _vnsprintf -#define __ETL_HAS_VSNPRINTF -#endif -#endif - /* === T Y P E D E F S ===================================================== */ _ETL_BEGIN_CDECLS @@ -73,13 +66,13 @@ _ETL_BEGIN_CDECLS // Prefer prototypes from glibc headers, since defining them ourselves // works around glibc security mechanisms -#ifdef __ETL_HAS_VASPRINTF // This is the preferred method +#ifdef HAVE_VASPRINTF // This is the preferred method #ifndef __GLIBC__ extern int vasprintf(char **,const char *,va_list)ETL_NO_THROW; #endif #else -# ifdef __ETL_HAS_VSNPRINTF // This is the secondary method +# ifdef HAVE_VSNPRINTF // This is the secondary method #ifndef __GLIBC__ extern int vsnprintf(char *,size_t,const char*,va_list)ETL_NO_THROW; #endif @@ -87,13 +80,13 @@ _ETL_BEGIN_CDECLS #endif -#ifdef __ETL_HAS_VSSCANF +#ifdef HAVE_VSSCANF #ifndef __GLIBC__ extern int vsscanf(const char *,const char *,va_list)ETL_NO_THROW; #endif #else #define ETL_NO_VSTRSCANF -#ifdef __ETL_HAS_SSCANF +#ifdef HAVE_SSCANF #ifndef __GLIBC__ extern int sscanf(const char *buf, const char *format, ...)ETL_NO_THROW; #endif @@ -111,7 +104,7 @@ _ETL_BEGIN_NAMESPACE inline std::string vstrprintf(const char *format, va_list args) { -#ifdef __ETL_HAS_VASPRINTF // This is the preferred method (and safest) +#ifdef HAVE_VASPRINTF // This is the preferred method (and safest) char *buffer; std::string ret; int i=vasprintf(&buffer,format,args); @@ -122,7 +115,7 @@ vstrprintf(const char *format, va_list args) } return ret; #else -#ifdef __ETL_HAS_VSNPRINTF // This is the secondary method (Safe, but bulky) +#ifdef HAVE_VSNPRINTF // This is the secondary method (Safe, but bulky) #warning etl::vstrprintf() has a maximum size of ETL_STRPRINTF_MAX_LENGTH in this configuration. #ifdef ETL_THREAD_SAFE char buffer[ETL_STRPRINTF_MAX_LENGTH]; @@ -171,7 +164,7 @@ strscanf(const std::string &data, const char*format, ...) } #else -#if defined (__ETL_HAS_SSCANF) && defined (__GNUC__) +#if defined (HAVE_SSCANF) && defined (__GNUC__) #define strscanf(data,format,...) sscanf(data.c_str(),format,__VA_ARGS__) #endif #endif diff --git a/ETL/trunk/ETL/_thread.h b/ETL/trunk/ETL/_thread.h index cb64933..8f70be8 100644 --- a/ETL/trunk/ETL/_thread.h +++ b/ETL/trunk/ETL/_thread.h @@ -31,21 +31,21 @@ #define __USE_GNU -#ifdef __ETL_HAS_PTHREAD_H +#ifdef HAVE_PTHREAD_H # include #endif -#ifdef __ETL_HAS_SCHED_H +#ifdef HAVE_SCHED_H # include #endif -#ifdef __ETL_HAS_CREATETHREAD +#ifdef HAVE_CREATETHREAD # include #endif /* === M A C R O S ========================================================= */ -#if ( defined (__ETL_HAS_PTHREAD_CREATE) || defined (__ETL_HAS_CLONE) || defined (__ETL_HAS_CREATETHREAD) ) && !defined (NO_THREADS) +#if ( defined (HAVE_PTHREAD_CREATE) || defined (HAVE_CLONE) || defined (HAVE_CREATETHREAD) ) && !defined (NO_THREADS) # define CALLISTO_THREADS #endif @@ -53,7 +53,7 @@ /* === C L A S S E S & S T R U C T S ======================================= */ -#if defined(CALLISTO_THREADS) && defined(__ETL_HAS_PTHREAD_CREATE) +#if defined(CALLISTO_THREADS) && defined(HAVE_PTHREAD_CREATE) static inline void Yield(void) { sched_yield(); @@ -68,7 +68,7 @@ inline void Yield(void) { } #ifdef CALLISTO_THREADS -#ifdef __ETL_HAS_PTHREAD_CREATE +#ifdef HAVE_PTHREAD_CREATE class Thread { @@ -207,7 +207,7 @@ public: } }; -#ifdef __ETL_HAS_PTHREAD_RW_LOCK_INIT +#ifdef HAVE_PTHREAD_RW_LOCK_INIT class ReadWriteLock { pthread_rwlock_t rwlock; @@ -290,8 +290,8 @@ public: }; */ -#else // if defined __ETL_HAS_PTHREAD_CREATE -#ifdef __ETL_HAS_CREATETHREAD +#else // if defined HAVE_PTHREAD +#ifdef HAVE_CREATETHREAD #ifdef THREAD_ENTRYPOINT @@ -448,8 +448,8 @@ public: }; -#endif // if defined __ETL_HAS_CREATETHREAD -#endif // if defined __ETL_HAS_PTHREAD_CREATE +#endif // if defined HAVE_CREATETHREAD +#endif // if defined HAVE_PTHREAD_CREATE #endif // if defined CALLISTO_THREADS diff --git a/ETL/trunk/ETL/clock b/ETL/trunk/ETL/clock index 73ec6ea..2457b6c 100644 --- a/ETL/trunk/ETL/clock +++ b/ETL/trunk/ETL/clock @@ -29,7 +29,7 @@ #include "etl_config.h" -#ifdef __ETL_HAS_GETTIMEOFDAY +#ifdef HAVE_GETTIMEOFDAY #include "_clock_gettimeofday.h" #ifndef ETL_CLOCK_DEFAULT_DESC_CLASS #define ETL_CLOCK_DEFAULT_DESC_CLASS _ETL::clock_desc_gettimeofday diff --git a/ETL/trunk/ETL/etl_config.h b/ETL/trunk/ETL/etl_config.h index 4e1be8d..94b4056 100644 --- a/ETL/trunk/ETL/etl_config.h +++ b/ETL/trunk/ETL/etl_config.h @@ -3,7 +3,7 @@ #ifndef __ETL_CONFIG_H #define __ETL_CONFIG_H -#include +#include "etl_profile.h" #include #ifndef ETL_NAMESPACE diff --git a/ETL/trunk/ETL/etl_profile.h.in b/ETL/trunk/ETL/etl_profile.h.in deleted file mode 100644 index e5b59b5..0000000 --- a/ETL/trunk/ETL/etl_profile.h.in +++ /dev/null @@ -1,42 +0,0 @@ -/* - * - * ETL platform-specific configuration header - * - * Built platform: @build@ - * Host platform: @host@ - * - */ - -#ifndef __ETL_PROFILE_H__ -#define __ETL_PROFILE_H__ - -// Public ETL definitions - -#define ETL_NAME "@PACKAGE_NAME@" -#define ETL_TARNAME "@PACKAGE_TARNAME@" -#define ETL_VERSION "@PACKAGE_VERSION@" - -// Private ETL definitions - -// Libraries -@D_LIBPTHREAD@ __ETL_HAS_LIBPTHREAD - -// Headers -@D_PTHREAD_H@ __ETL_HAS_PTHREAD_H -@D_SCHED_H@ __ETL_HAS_SCHED_H - -// Functions -@D_PTHREAD_CREATE@ __ETL_HAS_PTHREAD_CREATE -@D_PTHREAD_RWLOCK_INIT@ __ETL_HAS_PTHREAD_RWLOCK_INIT -@D_SCHED_YIELD@ __ETL_HAS_SCHED_YIELD -@D_CREATETHREAD@ __ETL_HAS_CREATETHREAD -@D_QUERYPERFORMANCECOUNTER@ __ETL_HAS_QUERYPERFORMANCECOUNTER -@D_GETTIMEOFDAY@ __ETL_HAS_GETTIMEOFDAY -@D_SSCANF@ __ETL_HAS_SSCANF -@D_VSSCANF@ __ETL_HAS_VSSCANF -@D_VSPRINTF@ __ETL_HAS_VSPRINTF -@D_VASPRINTF@ __ETL_HAS_VASPRINTF -@D_VSNPRINTF@ __ETL_HAS_VSNPRINTF -@D__VSNPRINTF@ __ETL_HAS__VSNPRINTF - -#endif // __ETL_PROFILE_H__ diff --git a/ETL/trunk/ETL/handle b/ETL/trunk/ETL/handle index d5ef74a..76508bc 100644 --- a/ETL/trunk/ETL/handle +++ b/ETL/trunk/ETL/handle @@ -33,12 +33,12 @@ // include the next line in an attempt to increase stability // it seems to make things much *less* stable on MS Windows #ifndef _WIN32 -#ifdef __ETL_HAS_LIBPTHREAD -#define __ETL_LOCK_REFCOUNTS +#ifdef HAVE_LIBPTHREAD +#define ETL_LOCK_REFCOUNTS #endif #endif -#ifdef __ETL_LOCK_REFCOUNTS +#ifdef ETL_LOCK_REFCOUNTS # include "mutex" #endif diff --git a/ETL/trunk/ETL/mutex b/ETL/trunk/ETL/mutex index 03fa734..f4d1263 100644 --- a/ETL/trunk/ETL/mutex +++ b/ETL/trunk/ETL/mutex @@ -29,7 +29,7 @@ #include "etl_config.h" -#ifdef __ETL_HAS_LIBPTHREAD +#ifdef HAVE_LIBPTHREAD # include "_mutex_pthreads_simple.h" #else #ifdef _WIN32 diff --git a/ETL/trunk/Makefile.am b/ETL/trunk/Makefile.am index 40d9abf..48447b7 100644 --- a/ETL/trunk/Makefile.am +++ b/ETL/trunk/Makefile.am @@ -21,6 +21,7 @@ MAINTAINERCLEANFILES = \ config.status \ .doc_stamp \ .DS_Store \ + include/etl_profile.h.in \ doxygen.cfg @@ -45,6 +46,7 @@ EXTRA_DIST = \ config/depcomp \ m4/cxx_macros.m4 \ ETL.pbproj/project.pbxproj \ + ETL.pbproj/etl_profile.h \ ETL.pbproj/frameworkfix.cpp \ ETL-config.in \ m4/ETL.m4 \ diff --git a/ETL/trunk/configure.ac b/ETL/trunk/configure.ac index fff4a6a..63f5e96 100644 --- a/ETL/trunk/configure.ac +++ b/ETL/trunk/configure.ac @@ -6,7 +6,7 @@ AC_INIT([Extended Template Library],[0.04.12],[http://synfig.org/Bugs],[ETL]) AC_REVISION AC_CONFIG_AUX_DIR(config) -AC_CONFIG_HEADERS([config.h]) +AC_CONFIG_HEADERS([ETL/etl_profile_.h]) AC_CANONICAL_HOST AC_CANONICAL_TARGET @@ -41,41 +41,27 @@ AC_WIN32_QUIRKS # -- L I B R A R I E S ---------------------------------------- -AC_CHECK_LIB([user32], [main]) -AC_CHECK_LIB([kernel32], [CreateMutex]) -AC_CHECK_LIB([pthread], [pthread_mutex_init], , [HAVE_LIBPTHREAD=no]) +# -- H E A D E R S -------------------------------------------- -if test x$HAVE_LIBPTHREAD = xno ; then - D_LIBPTHREAD="#undef" -else - D_LIBPTHREAD="#define" -fi +AH_TOP([ +// We want to be autoconf/autoheader friendly, so +// if the developer has already included an +// autoheader-generated configuration script, +// we can assume that the user knew what they +// were doing and let them use their own config.h. +//#ifndef PACKAGE_TARNAME +]) -# -- H E A D E R S -------------------------------------------- +AH_BOTTOM([ +//#endif // ifndef PACKAGE_TARNAME +]) -AC_HEADER_STDC -AC_CHECK_HEADERS([pthread.h], [D_PTHREAD_H="#define"], [D_PTHREAD_H="#undef"]) -AC_CHECK_HEADERS([sched.h], [D_SCHED_H="#define"], [D_SCHED_H="#undef"]) -AC_CHECK_HEADERS([sys/time.h]) -AC_CHECK_HEADERS([unistd.h]) -AC_CHECK_HEADERS([windows.h]) # -- T Y P E S & S T R U C T S -------------------------------- # -- F U N C T I O N S ---------------------------------------- -AC_CHECK_FUNCS([pthread_create], [D_PTHREAD_CREATE="#define"], [D_PTHREAD_CREATE="#undef"]) -AC_CHECK_FUNCS([pthread_rwlock_init], [D_PTHREAD_RWLOCK_INIT="#define"], [D_PTHREAD_RWLOCK_INIT="#undef"]) -AC_CHECK_FUNCS([sched_yield], [D_SCHED_YIELD="#define"], [D_SCHED_YIELD="#undef"]) -AC_CHECK_FUNCS([CreateThread], [D_CREATETHREAD="#define"], [D_CREATETHREAD="#undef"]) -AC_CHECK_FUNCS([QueryPerformanceCounter], [D_QUERYPERFORMANCECOUNTER="#define"], [D_QUERYPERFORMANCECOUNTER="#undef"]) -AC_CHECK_FUNCS([gettimeofday], [D_GETTIMEOFDAY="#define"], [D_GETTIMEOFDAY="#undef"]) -AC_CHECK_FUNCS([sscanf], [D_SSCANF="#define"], [D_SSCANF="#undef"]) -AC_CHECK_FUNCS([vsscanf], [D_VSSCANF="#define"], [D_VSSCANF="#undef"]) -AC_CHECK_FUNCS([vsprintf], [D_VSPRINTF="#define"], [D_VSPRINTF="#undef"]) -AC_CHECK_FUNCS([vasprintf], [D_VASPRINTF="#define"], [D_VASPRINTF="#undef"]) -AC_CHECK_FUNCS([vsnprintf], [D_VSNPRINTF="#define"], [D_VSNPRINTF="#undef"]) -AC_CHECK_FUNCS([_vsnprintf], [D__VSNPRINTF="#define"], [D__VSNPRINTF="#undef"]) +ETL_DEPS # -- O U T P U T ---------------------------------------------- @@ -83,29 +69,7 @@ AC_SUBST(CFLAGS) AC_SUBST(CPPFLAGS) AC_SUBST(LDFLAGS) -# Libraries -AC_SUBST(D_LIBPTHREAD) - -# Headers -AC_SUBST(D_PTHREAD_H) -AC_SUBST(D_SCHED_H) - -# Functions -AC_SUBST(D_PTHREAD_CREATE) -AC_SUBST(D_PTHREAD_RWLOCK_INIT) -AC_SUBST(D_SCHED_YIELD) -AC_SUBST(D_CREATETHREAD) -AC_SUBST(D_QUERYPERFORMANCECOUNTER) -AC_SUBST(D_GETTIMEOFDAY) -AC_SUBST(D_SSCANF) -AC_SUBST(D_VSSCANF) -AC_SUBST(D_VSPRINTF) -AC_SUBST(D_VASPRINTF) -AC_SUBST(D_VSNPRINTF) -AC_SUBST(D__VSNPRINTF) - AC_CONFIG_FILES([ETL-config -ETL/etl_profile.h Makefile ETL/Makefile test/Makefile diff --git a/ETL/trunk/m4/ETL.m4 b/ETL/trunk/m4/ETL.m4 index 08ae7ba..c2dc7a4 100644 --- a/ETL/trunk/m4/ETL.m4 +++ b/ETL/trunk/m4/ETL.m4 @@ -5,6 +5,38 @@ # By Robert B. Quattlebaum Jr. # +AC_DEFUN([ETL_DEPS], +[ + AC_CHECK_LIB(user32, main) + AC_CHECK_LIB([kernel32], [CreateMutex]) + AC_CHECK_LIB([pthread], [pthread_mutex_init]) + + AC_HEADER_STDC + + AC_CHECK_HEADERS(pthread.h) + AC_CHECK_HEADERS(sched.h) + AC_CHECK_HEADERS(sys/time.h) + AC_CHECK_HEADERS(unistd.h) + AC_CHECK_HEADERS(windows.h) + AC_CHECK_FUNCS([pthread_create]) + AC_CHECK_FUNCS([pthread_rwlock_init]) + AC_CHECK_FUNCS([sched_yield]) + AC_CHECK_FUNCS([CreateThread]) + AC_CHECK_FUNCS([QueryPerformanceCounter]) + + AC_CHECK_FUNCS([gettimeofday]) + AC_CHECK_FUNCS([sscanf]) + AC_CHECK_FUNCS([vsscanf]) + AC_CHECK_FUNCS([vsprintf]) + AC_CHECK_FUNCS([vasprintf]) + AC_CHECK_FUNCS([vsnprintf],[],[ + AC_CHECK_FUNC([_vsnprintf],[ + AC_DEFINE(vsnprintf,_vsnprintf,[define if the vsnprintf function is mangled]) + AC_DEFINE(HAVE_VSNPRINTF,1) + ]) + ]) +]) + AC_DEFUN([USING_ETL], [ AC_ARG_WITH(ETL-includes, diff --git a/synfig-core/trunk/src/synfig/valuenode_scale.cpp b/synfig-core/trunk/src/synfig/valuenode_scale.cpp index a0bba53..b272d7d 100644 --- a/synfig-core/trunk/src/synfig/valuenode_scale.cpp +++ b/synfig-core/trunk/src/synfig/valuenode_scale.cpp @@ -141,6 +141,50 @@ synfig::ValueNode_Scale::operator()(Time t)const return ValueBase(); } +synfig::ValueBase +synfig::ValueNode_Scale::get_inverse(Time t, const synfig::Vector &target_value) const +{ + Real scalar_value((*scalar)(t).get(Real())); + if(scalar_value==0) + throw runtime_error(strprintf("ValueNode_Scale: %s",_("Attempting to get the inverse of a non invertible Valuenode"))); + else + { + switch (get_type()) + { + case ValueBase::TYPE_REAL: + return target_value.mag() / scalar_value; + case ValueBase::TYPE_ANGLE: + return Angle::tan(target_value[1] / scalar_value ,target_value[0] / scalar_value); + default: + return target_value / scalar_value; + } + } + return ValueBase(); +} + +synfig::ValueBase +synfig::ValueNode_Scale::get_inverse(Time t, const synfig::Angle &target_value) const +{ + Real scalar_value((*scalar)(t).get(Real())); + if(scalar_value==0) + throw runtime_error(strprintf("ValueNode_Scale: %s",_("Attempting to get the inverse of a non invertible Valuenode"))); + else + { + switch (get_type()) + { + default: + return (*value_node)(t).get(Angle()) + target_value / scalar_value; + } + } + return ValueBase(); +} + +bool +synfig::ValueNode_Scale::is_invertible(Time t) const +{ + Real scalar_value((*scalar)(t).get(Real())); + return (!scalar_value==0); +} bool ValueNode_Scale::set_link_vfunc(int i,ValueNode::Handle value) diff --git a/synfig-core/trunk/src/synfig/valuenode_scale.h b/synfig-core/trunk/src/synfig/valuenode_scale.h index bb1ccd0..fba1aa0 100644 --- a/synfig-core/trunk/src/synfig/valuenode_scale.h +++ b/synfig-core/trunk/src/synfig/valuenode_scale.h @@ -64,6 +64,12 @@ public: virtual ValueBase operator()(Time t)const; + //! Returns the modified Link to match the target value at time t + ValueBase get_inverse(Time t, const synfig::Vector &target_value) const; + ValueBase get_inverse(Time t, const synfig::Angle &target_value) const; + + bool is_invertible(Time t)const; + virtual String get_name()const; virtual String get_local_name()const; diff --git a/synfig-studio/trunk/images/Makefile.am b/synfig-studio/trunk/images/Makefile.am index 5db7c38..84e53fa 100644 --- a/synfig-studio/trunk/images/Makefile.am +++ b/synfig-studio/trunk/images/Makefile.am @@ -74,8 +74,16 @@ EXTRA_DIST = \ seek_begin.sif \ seek_end.sif \ seek_next_frame.sif \ - seek_prev_frame.sif - + seek_prev_frame.sif \ + duck_position_icon.sif \ + duck_vertex_icon.sif \ + duck_tangent_icon.sif \ + duck_radius_icon.sif \ + duck_width_icon.sif \ + duck_angle_icon.sif \ + show_grid_icon.sif \ + snap_grid_icon.sif \ + onion_skin_icon.sif IMAGES = \ @@ -147,7 +155,16 @@ IMAGES = \ seek_begin.$(EXT) \ seek_end.$(EXT) \ seek_next_frame.$(EXT) \ - seek_prev_frame.$(EXT) + seek_prev_frame.$(EXT) \ + duck_position_icon.$(EXT) \ + duck_vertex_icon.$(EXT) \ + duck_tangent_icon.$(EXT) \ + duck_radius_icon.$(EXT) \ + duck_width_icon.$(EXT) \ + duck_angle_icon.$(EXT) \ + show_grid_icon.$(EXT) \ + snap_grid_icon.$(EXT) \ + onion_skin_icon.$(EXT) MAINTAINERCLEANFILES = \ diff --git a/synfig-studio/trunk/images/duck_angle_icon.sif b/synfig-studio/trunk/images/duck_angle_icon.sif new file mode 100644 index 0000000..882da55 --- /dev/null +++ b/synfig-studio/trunk/images/duck_angle_icon.sif @@ -0,0 +1,1139 @@ + + + Duck Angle Icon. + Copyright 2009 Carlos López and Gerald Young. Released under GNU Public License published by the Free Software Foundation version 2.0 of the License or any later version. + + + + + + + + + + + + + + + + + + + 0.172709 + 0.660939 + 1.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + -3.0423660278 + -2.5353050232 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1.0288373232 + 1.5358983278 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1.5358983278 + 1.0288373232 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -2.5353050232 + -3.0423660278 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + -3.0423660278 + -2.5353050232 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1.0288373232 + 1.5358983278 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1.5358983278 + 1.0288373232 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -2.5353050232 + -3.0423660278 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 1.000000 + 1.000000 + + + + + 2.0282440186 + 2.0282440186 + + + + + + + + + + + + + + + + + + + + + + + + 1.0141220093 + -0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -0.0082739592 + 1.0223959684 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -1.0306698084 + -0.0000000894 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -0.0082738996 + -1.0223959684 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 2.0282440186 + 2.0282440186 + + + + + + + + + + + + + + + + + + + + + + + + 1.0141220093 + -0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -0.0082739592 + 1.0223959684 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -1.0306698084 + -0.0000000894 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -0.0082738996 + -1.0223959684 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + -2.5353050232 + -3.0423660278 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 3.0423660278 + -3.0423660278 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + -2.5353050232 + -3.0423660278 + + + + + + + + + + + + + + + + + + + + + + + + 4.0564880371 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 2.8683700562 + 2.8683700562 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/synfig-studio/trunk/images/duck_position_icon.sif b/synfig-studio/trunk/images/duck_position_icon.sif new file mode 100644 index 0000000..ef219c0 --- /dev/null +++ b/synfig-studio/trunk/images/duck_position_icon.sif @@ -0,0 +1,959 @@ + + + Duck Position Icon. + Copyright 2009 Carlos López and Gerald Young. Released under GNU Public License published by the Free Software Foundation version 2.0 of the License or any later version. + + + + + + + + + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + 1.000000 + 1.000000 + 1.000000 + 1.000000 + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + 1.000000 + 1.000000 + 1.000000 + 1.000000 + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + 1.6642030478 + -1.9762411118 + + + + + -0.6339452267 + 0.8150724769 + + + + + + 0.064115 + 0.064115 + 0.064115 + 1.000000 + + + 1.000000 + 1.000000 + 1.000000 + 1.000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 1.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + 1.0194250345 + 0.0000000290 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -0.0000000515 + 1.0194250345 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -1.0194250345 + -0.0000000601 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.0000000052 + -1.0194250345 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + 1.0194250345 + 0.0000000290 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -0.0000000515 + 1.0194250345 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -1.0194250345 + -0.0000000601 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.0000000052 + -1.0194250345 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + -2.9076893330 + 0.5070610046 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -0.5070610046 + 2.0282440186 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 2.5353050232 + 2.9336509705 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 2.0282440186 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.1557690650 + -2.6480741501 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -1.5211830139 + -1.0141220093 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/synfig-studio/trunk/images/duck_radius_icon.sif b/synfig-studio/trunk/images/duck_radius_icon.sif new file mode 100644 index 0000000..b50a62d --- /dev/null +++ b/synfig-studio/trunk/images/duck_radius_icon.sif @@ -0,0 +1,1232 @@ + + + Duck Vertex Icon. + Copyright 2009 Carlos López and Gerald Young. Released under GNU Public License published by the Free Software Foundation version 2.0 of the License or any later version. + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + 2.5353050232 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -0.0000001108 + 2.5353050232 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -2.5353050232 + -0.0000002216 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.0000000302 + -2.5353050232 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.488248 + 1.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + 2.3105745316 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -0.0000001010 + 2.3105745316 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -2.3105745316 + -0.0000002020 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.0000000276 + -2.3105745316 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + 2.0309278965 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -0.0000000888 + 2.0309278965 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -2.0309278965 + -0.0000001775 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.0000000242 + -2.0309278965 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + 1.8432673216 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -0.0000000806 + 1.8432673216 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -1.8432673216 + -0.0000001611 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.0000000220 + -1.8432673216 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 1.000000 + 1.000000 + 1.000000 + + + + + 2.0282440186 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + 1.0141220093 + 0.0000000291 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -0.0000000513 + 1.0141220093 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -1.0141220093 + -0.0000000595 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.0000000051 + -1.0141220093 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 2.0282440186 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + 1.0141220093 + 0.0000000291 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -0.0000000513 + 1.0141220093 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -1.0141220093 + -0.0000000595 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.0000000051 + -1.0141220093 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/synfig-studio/trunk/images/duck_tangent_icon.sif b/synfig-studio/trunk/images/duck_tangent_icon.sif new file mode 100644 index 0000000..0fead6c --- /dev/null +++ b/synfig-studio/trunk/images/duck_tangent_icon.sif @@ -0,0 +1,1838 @@ + + + Duck Tangent Icon. + Copyright 2009 Carlos López and Gerald Young. Released under GNU Public License published by the Free Software Foundation version 2.0 of the License or any later version. + + + + + + + + + + + + + + + + + + + 0.172709 + 0.660939 + 1.000000 + 1.000000 + + + + + -0.5070610046 + 2.0282440186 + + + + + + + + + + + + + + + + + + + + + + + + -2.5107734203 + 0.3518353105 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 2.5088565350 + 0.3652547002 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 2.5107734203 + -0.3518353105 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -2.5088565350 + -0.3652547002 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + -0.5070610046 + 2.0282440186 + + + + + + + + + + + + + + + + + + + + + + + + -2.5107734203 + 0.3518353105 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 2.5088565350 + 0.3652547002 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 2.5107734203 + -0.3518353105 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -2.5088565350 + -0.3652547002 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.172709 + 0.660939 + 1.000000 + 1.000000 + + + + + 0.5070610046 + -2.0282440186 + + + + + + + + + + + + + + + + + + + + + + + + -2.5107734203 + 0.3518353105 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 2.5088565350 + 0.3652547002 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 2.5107734203 + -0.3518353105 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -2.5088565350 + -0.3652547002 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + -3.0423660278 + 2.0282440186 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 3.0423660278 + -2.0282440186 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.5070610046 + -2.0282440186 + + + + + + + + + + + + + + + + + + + + + + + + -2.5107734203 + 0.3518353105 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 2.5088565350 + 0.3652547002 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 2.5107734203 + -0.3518353105 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -2.5088565350 + -0.3652547002 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 2.0282440186 + 2.0282440186 + + + + + + + + + + + + + + + + + + + + + + + + 1.0194891691 + 0.0000000290 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -0.0000000515 + 1.0194891691 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -1.0194891691 + -0.0000000601 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.0000000052 + -1.0194891691 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 2.0282440186 + 2.0282440186 + + + + + + + + + + + + + + + + + + + + + + + + 1.0194891691 + 0.0000000290 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -0.0000000515 + 1.0194891691 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -1.0194891691 + -0.0000000601 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.0000000052 + -1.0194891691 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1.000000 + 1.000000 + 0.000000 + 1.000000 + + + + + -2.0282440186 + -2.0282440186 + + + + + + + + + + + + + + + + + + + + + + + + 1.0264549255 + 0.0000000288 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -0.0000000517 + 1.0264549255 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -1.0264549255 + -0.0000000609 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.0000000053 + -1.0264549255 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + -2.0282440186 + -2.0282440186 + + + + + + + + + + + + + + + + + + + + + + + + 1.0264549255 + 0.0000000288 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -0.0000000517 + 1.0264549255 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -1.0264549255 + -0.0000000609 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.0000000053 + -1.0264549255 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/synfig-studio/trunk/images/duck_vertex_icon.sif b/synfig-studio/trunk/images/duck_vertex_icon.sif new file mode 100644 index 0000000..ff7bba5 --- /dev/null +++ b/synfig-studio/trunk/images/duck_vertex_icon.sif @@ -0,0 +1,575 @@ + + + Duck Vertex Icon. + Copyright 2009 Carlos López and Gerald Young. Released under GNU Public License published by the Free Software Foundation version 2.0 of the License or any later version. + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + -3.0423660278 + 3.0423660278 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 3.0423660278 + -3.0423660278 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1.000000 + 0.498039 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + 1.0141220093 + 0.0000000291 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -0.0000000513 + 1.0141220093 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -1.0141220093 + -0.0000000596 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.0000000051 + -1.0141220093 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + 1.0141220093 + 0.0000000291 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -0.0000000513 + 1.0141220093 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -1.0141220093 + -0.0000000596 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.0000000051 + -1.0141220093 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/synfig-studio/trunk/images/duck_width_icon.sif b/synfig-studio/trunk/images/duck_width_icon.sif new file mode 100644 index 0000000..19f7199 --- /dev/null +++ b/synfig-studio/trunk/images/duck_width_icon.sif @@ -0,0 +1,1426 @@ + + + Duck Width Icon. + Copyright 2009 Carlos López and Gerald Young. Released under GNU Public License published by the Free Software Foundation version 2.0 of the License or any later version. + + + + + + + + + + + + + + + + + + + 0.0000000000 + -0.5070610046 + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + 2.5394833088 + 0.0000000046 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -0.0000001121 + 2.5394833088 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -2.5394833088 + -0.0000002174 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.0000000292 + -2.5394835472 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.488248 + 1.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + 2.3143825531 + 0.0000000046 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -0.0000001023 + 2.3143825531 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -2.3143825531 + -0.0000001978 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.0000000265 + -2.3143825531 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + 2.0342750549 + 0.0000000046 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -0.0000000900 + 2.0342750549 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -2.0342750549 + -0.0000001732 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.0000000231 + -2.0342750549 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + 1.8463052511 + 0.0000000046 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -0.0000000818 + 1.8463052511 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -1.8463052511 + -0.0000001568 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.0000000209 + -1.8463051319 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + -3.0216197968 + 2.5601470470 + + + + + + + + + + + + + + 3.7107613087 + 3.3926959038 + + + + + 3.7107613087 + 3.3926959038 + + + + + + + + + 0.0000000000 + -0.0373858735 + + + + + + + + + + + + + + 0.7456641793 + -3.0892977715 + + + + + 0.7456641793 + -3.0892977715 + + + + + + + + + 3.0216197968 + -2.7939512730 + + + + + + + + + + + + + + 5.6191525459 + 2.5975327492 + + + + + 5.6191525459 + 2.5975327492 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1.000000 + 0.000000 + 1.000000 + 1.000000 + + + + + 2.0282440186 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + 1.0194250345 + 0.0000000290 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -0.0000000515 + 1.0194250345 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -1.0194250345 + -0.0000000601 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.0000000052 + -1.0194250345 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 2.0282440186 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + 1.0194250345 + 0.0000000290 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -0.0000000515 + 1.0194250345 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -1.0194250345 + -0.0000000601 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.0000000052 + -1.0194250345 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/synfig-studio/trunk/images/onion_skin_icon.sif b/synfig-studio/trunk/images/onion_skin_icon.sif new file mode 100644 index 0000000..c05b49a --- /dev/null +++ b/synfig-studio/trunk/images/onion_skin_icon.sif @@ -0,0 +1,3897 @@ + + + Onion Skin Icon + opyright 2009 Carlos López. Released under GNU Public License published by the Free Software Foundation version 2.0 of the License or any later version. + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + -2.9229531288 + -2.9576816559 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.1877044588 + -3.2387652397 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 3.3171010017 + -2.8265094757 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.1127488539 + -2.4892091751 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.068320 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + 1.1829863787 + -2.1152374744 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1.8230646849 + -2.4402816296 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.068320 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + 0.5269945860 + -2.3839306831 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.4706437290 + -3.1352758408 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.068320 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + 0.7523981333 + -2.3651473522 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1.0153688192 + -2.9098720551 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.068320 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + 0.9449565411 + -2.2688050270 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1.4661759138 + -2.7408194542 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + 0.368591 + 0.054592 + 0.000367 + 1.000000 + + + + + -0.0643781647 + -0.2328656912 + + + + + + + + + + + + + + + + + + + + + + + + -2.3215346336 + 3.2606282234 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -1.8768180609 + 3.0616166592 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -1.4014495611 + 2.6467370987 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1.0805414915 + 2.2623436451 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 2.6633694172 + -0.6326169372 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -1.6852339506 + -2.3124501705 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -2.4364871979 + 0.5622851253 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -1.8326535225 + 2.6206669807 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + 1.000000 + 1.000000 + 1.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + -1.0193932056 + 1.8821717501 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -1.9770790339 + 2.8565862179 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -0.8248791099 + 2.0168352127 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1.8384674788 + 1.1490032673 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1.3447009325 + -1.9482592344 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1.4344767332 + 0.9245639443 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1.000000 + 1.000000 + 1.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + -1.8273745775 + 2.6303029060 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -0.9146548510 + 1.6876575947 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1.3147757053 + 0.5804236531 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.9706354141 + -2.2026238441 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.8958223462 + 0.3709469736 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -1.2587951422 + 1.7624707222 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1.000000 + 1.000000 + 1.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + -1.8423373699 + 2.8397793770 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -1.3503803015 + -0.6677243114 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.8021189570 + -2.2205784321 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -0.9296174645 + -0.3921466768 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1.000000 + 1.000000 + 1.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + -1.6627858877 + 2.2412745953 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -0.2413368821 + -0.0928942785 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.7761213183 + -2.1726987362 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -0.6004397869 + -0.3023709953 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1.000000 + 1.000000 + 1.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + -1.8124120235 + 2.5255644321 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.4020558298 + 0.3859095871 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.8359718919 + -2.2325491905 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -0.0318601802 + 0.1315450519 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1.000000 + 1.000000 + 1.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + -1.8707103729 + 2.7586135864 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -1.6582746506 + 1.4638130665 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -1.9770009518 + -1.0355393887 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.3404104412 + -2.3694448471 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -1.7076736689 + -0.7961374521 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -1.5131137371 + 1.7846834660 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1.000000 + 1.000000 + 1.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + -1.6627858877 + 1.5679566860 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -2.1719386578 + 2.8153848648 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -1.7675241232 + 1.5230687857 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -2.4707674980 + -1.3497544527 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.3466558754 + -2.4507670403 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -2.2240104675 + -1.1337386370 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.4867386520 + 0.3261826038 + + + + + -1.1016255617 + -0.5668530464 + + + + + + + + 1.000000 + 0.526239 + 0.229116 + 1.000000 + + + 0.368591 + 0.054592 + 0.000367 + 1.000000 + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 0.000000 + + + + + 0.000000 + 0.000000 + 0.000000 + 0.000000 + + + + + + + + + + + + + + + -0.2920670211 + -0.0973556712 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.368590 + 0.093209 + 0.000000 + 1.000000 + + + 0.614758 + 0.205665 + 0.000000 + 1.000000 + + + + + + -0.0933790579 + -0.1468464881 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1.000000 + 1.000000 + 1.000000 + 0.000000 + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1.000000 + 1.000000 + 1.000000 + 0.492537 + + + 0.368591 + 0.054592 + 0.000367 + 0.000000 + + + + + + -1.5252388716 + -0.7139415741 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.668137 + 0.445613 + 0.180129 + 1.000000 + + + + + -0.0643781647 + -0.2328656912 + + + + + + + + + + + + + + + + + + + + + + + + -2.3215346336 + 3.2606282234 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -1.8768180609 + 3.0616166592 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -1.4014495611 + 2.6467370987 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1.0805414915 + 2.2623436451 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 2.6633694172 + -0.6326169372 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -1.6852339506 + -2.3124501705 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -2.4364871979 + 0.5622851253 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -1.8326535225 + 2.6206669807 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.136579 + 0.025753 + 0.003409 + 1.000000 + + + + + -0.0643781647 + -0.2328656912 + + + + + + + + + + + + + + + + + + + + + + + + -2.5124592781 + 3.4483561516 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -1.7273231745 + 3.2022943497 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -1.2700022459 + 2.7833168507 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1.1697320938 + 2.4385998249 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 2.8539276123 + -0.6387156248 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -1.7990334034 + -2.4649844170 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -2.6231255531 + 0.6254264116 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -2.0307235718 + 2.5930707455 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/synfig-studio/trunk/images/show_grid_icon.sif b/synfig-studio/trunk/images/show_grid_icon.sif new file mode 100644 index 0000000..8799241 --- /dev/null +++ b/synfig-studio/trunk/images/show_grid_icon.sif @@ -0,0 +1,1155 @@ + + + Show Grig Icon + Copyright 2009 Carlos López. Released under GNU Public License published by the Free Software Foundation version 2.0 of the License or any later version. + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + -3.1952149868 + 0.7988043427 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 3.1952171326 + 0.7988043427 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + -3.1952161789 + -0.7988040447 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 3.1952159405 + -0.7988040447 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + -3.1952161789 + -2.3964121342 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 3.1952159405 + -2.3964121342 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + -2.3964121342 + 3.1952161789 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -2.3964121342 + -3.1952161789 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + -0.7988041639 + 3.1952161789 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -0.7988041639 + -3.1952161789 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + 0.7988039255 + 3.1952161789 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.7988039255 + -3.1952161789 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + 2.3964118958 + 3.1952161789 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 2.3964118958 + -3.1952161789 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + -3.1952161789 + 2.3964121342 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 3.1952159405 + 2.3964121342 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/synfig-studio/trunk/images/snap_grid_icon.sif b/synfig-studio/trunk/images/snap_grid_icon.sif new file mode 100644 index 0000000..96c5613 --- /dev/null +++ b/synfig-studio/trunk/images/snap_grid_icon.sif @@ -0,0 +1,1155 @@ + + + Snap Grig Icon + Copyright 2009 Carlos López. Released under GNU Public License published by the Free Software Foundation version 2.0 of the License or any later version. + + + + + + + + + + + + + + + + + + + 0.100000 + 0.100000 + 0.100000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + -3.1952149868 + 0.7988043427 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 3.1952171326 + 0.7988043427 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.100000 + 0.100000 + 0.100000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + -3.1952161789 + -2.3964121342 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 3.1952159405 + -2.3964121342 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.100000 + 0.100000 + 0.100000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + -2.3964121342 + 3.1952161789 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -2.3964121342 + -3.1952161789 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.100000 + 0.100000 + 0.100000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + -0.7988041639 + 3.1952161789 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -0.7988041639 + -3.1952161789 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.100000 + 0.100000 + 0.100000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + 2.3964118958 + 3.1952161789 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 2.3964118958 + -3.1952161789 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.100000 + 0.100000 + 0.100000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + -3.1952161789 + 2.3964121342 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 3.1952159405 + 2.3964121342 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + -3.1952161789 + -0.7988040447 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 3.1952159405 + -0.7988040447 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1.000000 + 0.000000 + 0.000000 + 1.000000 + + + + + 0.0000000000 + 0.0000000000 + + + + + + + + + + + + + + + + + + + + + + + + 0.7988039255 + 3.1952161789 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.7988039255 + -3.1952161789 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/synfig-studio/trunk/src/gtkmm/Makefile.am b/synfig-studio/trunk/src/gtkmm/Makefile.am index 39acf8c..1be3e71 100644 --- a/synfig-studio/trunk/src/gtkmm/Makefile.am +++ b/synfig-studio/trunk/src/gtkmm/Makefile.am @@ -294,7 +294,9 @@ OTHER_HH = \ workarea.h \ zoomdial.h \ framedial.h \ - keyframedial.h + keyframedial.h \ + toggleducksdial.h \ + resolutiondial.h OTHER_CC = \ main.cpp \ @@ -326,8 +328,9 @@ OTHER_CC = \ workarea.cpp \ zoomdial.cpp \ framedial.cpp \ - keyframedial.cpp - + keyframedial.cpp \ + toggleducksdial.cpp \ + resolutiondial.cpp INCLUDES = \ -I$(top_srcdir)/src diff --git a/synfig-studio/trunk/src/gtkmm/app.cpp b/synfig-studio/trunk/src/gtkmm/app.cpp index 3099c44..27bdf4f 100644 --- a/synfig-studio/trunk/src/gtkmm/app.cpp +++ b/synfig-studio/trunk/src/gtkmm/app.cpp @@ -280,6 +280,8 @@ String studio::App::custom_filename_prefix(DEFAULT_FILENAME_PREFIX); int studio::App::preferred_x_size=480; int studio::App::preferred_y_size=270; String studio::App::predefined_size(DEFAULT_PREDEFINED_SIZE); +String studio::App::predefined_fps(DEFAULT_PREDEFINED_FPS); +float studio::App::preferred_fps=24.0; #ifdef USE_OPEN_FOR_URLS String studio::App::browser_command("open"); // MacOS only #else @@ -570,6 +572,16 @@ public: value=strprintf("%s",App::predefined_size.c_str()); return true; } + if(key=="preferred_fps") + { + value=strprintf("%f",App::preferred_fps); + return true; + } + if(key=="predefined_fps") + { + value=strprintf("%s",App::predefined_fps.c_str()); + return true; + } return synfigapp::Settings::get_value(key,value); } @@ -667,6 +679,18 @@ public: App::predefined_size=value; return true; } + if(key=="preferred_fps") + { + float i(atof(value.c_str())); + App::preferred_fps=i; + return true; + } + if(key=="predefined_fps") + { + App::predefined_fps=value; + return true; + } + return synfigapp::Settings::set_value(key,value); } @@ -689,6 +713,8 @@ public: ret.push_back("preferred_x_size"); ret.push_back("preferred_y_size"); ret.push_back("predefined_size"); + ret.push_back("preferred_fps"); + ret.push_back("predefined_fps"); return ret; } }; @@ -1768,6 +1794,8 @@ App::reset_initial_window_configuration() synfigapp::Main::settings().set_value("pref.preferred_x_size","480"); synfigapp::Main::settings().set_value("pref.preferred_y_size","270"); synfigapp::Main::settings().set_value("pref.predefined_size",DEFAULT_PREDEFINED_SIZE); + synfigapp::Main::settings().set_value("pref.preferred_fps","24.0"); + synfigapp::Main::settings().set_value("pref.predefined_fps",DEFAULT_PREDEFINED_FPS); synfigapp::Main::settings().set_value("window.toolbox.pos","4 4"); } @@ -2438,7 +2466,7 @@ App::new_instance() canvas->set_name(file_name); file_name += ".sifz"; - canvas->rend_desc().set_frame_rate(24.0); + canvas->rend_desc().set_frame_rate(preferred_fps); canvas->rend_desc().set_time_start(0.0); canvas->rend_desc().set_time_end(5.0); canvas->rend_desc().set_x_res(DPI2DPM(72.0f)); diff --git a/synfig-studio/trunk/src/gtkmm/app.h b/synfig-studio/trunk/src/gtkmm/app.h index 507bc75..89cd528 100644 --- a/synfig-studio/trunk/src/gtkmm/app.h +++ b/synfig-studio/trunk/src/gtkmm/app.h @@ -204,6 +204,8 @@ public: static int preferred_x_size; static int preferred_y_size; static synfig::String predefined_size; + static synfig::String predefined_fps; + static float preferred_fps; /* -- ** -- S I G N A L S ------------------------------------------------------- */ diff --git a/synfig-studio/trunk/src/gtkmm/canvasview.cpp b/synfig-studio/trunk/src/gtkmm/canvasview.cpp index a3c42cc..a76b1a0 100644 --- a/synfig-studio/trunk/src/gtkmm/canvasview.cpp +++ b/synfig-studio/trunk/src/gtkmm/canvasview.cpp @@ -7,6 +7,7 @@ ** \legal ** Copyright (c) 2002-2005 Robert B. Quattlebaum Jr., Adrian Bentley ** Copyright (c) 2007, 2008 Chris Moore +** Copyright (c) 2009 Carlos López ** ** This package is free software; you can redistribute it and/or ** modify it under the terms of the GNU General Public License as @@ -41,6 +42,7 @@ #include #include #include +#include #include #include @@ -682,6 +684,9 @@ CanvasView::CanvasView(etl::loose_handle instance,etl::handle instance,etl::handle instance,etl::handleattach(*vpaned, 0, 1, 0, 1, Gtk::EXPAND|Gtk::FILL, Gtk::EXPAND|Gtk::FILL, 0, 0); layout_table->attach(*create_work_area(), 0, 1, 1, 2, Gtk::EXPAND|Gtk::FILL, Gtk::EXPAND|Gtk::FILL, 0, 0); + layout_table->attach(*create_display_bar(), 0, 1, 0, 1, Gtk::EXPAND|Gtk::FILL, Gtk::SHRINK|Gtk::FILL, 0, 0); init_menus(); //layout_table->attach(*App::ui_manager()->get_widget("/menu-main"), 0, 1, 0, 1, Gtk::EXPAND|Gtk::FILL, Gtk::SHRINK|Gtk::FILL, 0, 0); @@ -1021,23 +1033,21 @@ CanvasView::create_time_bar() keyframedial->show(); keyframebutton=keyframedial->get_lock_button(); - Gtk::Table *table = manage(new class Gtk::Table(5, 3, false)); - timebar = table; + timebar = manage(new class Gtk::Table(5, 4, false)); - //Attach widgets to the time bar table - table->attach(*manage(disp_audio), 1, 5, 0, 1, Gtk::EXPAND|Gtk::FILL, Gtk::SHRINK); - table->attach(*framedial, 0, 1, 2, 3,Gtk::SHRINK, Gtk::SHRINK); - table->attach(*current_time_widget, 0, 1, 1, 2, Gtk::SHRINK|Gtk::FILL, Gtk::SHRINK|Gtk::FILL, 0, 0); - table->attach(*timeslider, 1, 3, 1, 2, Gtk::EXPAND|Gtk::FILL, Gtk::SHRINK); - table->attach(*time_window_scroll, 1, 3, 2, 3, Gtk::EXPAND|Gtk::FILL, Gtk::SHRINK); - table->attach(*keyframedial, 3, 4, 1, 2, Gtk::SHRINK, Gtk::SHRINK); - table->attach(*animatebutton, 4, 5, 1, 2, Gtk::SHRINK, Gtk::SHRINK); - //table->attach(*keyframebutton, 1, 2, 3, 4, Gtk::SHRINK, Gtk::SHRINK); + //Attach widgets to the timebar + timebar->attach(*manage(disp_audio), 1, 5, 0, 1, Gtk::EXPAND|Gtk::FILL, Gtk::SHRINK); + timebar->attach(*framedial, 0, 1, 2, 3,Gtk::SHRINK, Gtk::SHRINK); + timebar->attach(*current_time_widget, 0, 1, 1, 2, Gtk::SHRINK|Gtk::FILL, Gtk::SHRINK|Gtk::FILL, 0, 0); + timebar->attach(*timeslider, 1, 3, 1, 2, Gtk::EXPAND|Gtk::FILL, Gtk::SHRINK); + timebar->attach(*time_window_scroll, 1, 3, 2, 3, Gtk::EXPAND|Gtk::FILL, Gtk::SHRINK); + timebar->attach(*keyframedial, 3, 4, 1, 2, Gtk::SHRINK, Gtk::SHRINK); + timebar->attach(*animatebutton, 4, 5, 1, 2, Gtk::SHRINK, Gtk::SHRINK); + //timebar->attach(*keyframebutton, 1, 2, 3, 4, Gtk::SHRINK, Gtk::SHRINK); + timebar->show(); - table->show(); - - return table; + return timebar; } Gtk::Widget * @@ -1095,6 +1105,133 @@ CanvasView::create_status_bar() return statusbartable; } +Gtk::Widget* +CanvasView::create_display_bar() +{ + displaybar = manage(new class Gtk::Table(1, 7, false)); + + // Setup the ToggleDuckDial widget + toggleducksdial = Gtk::manage(new class ToggleDucksDial()); + + Duck::Type m = work_area->get_type_mask(); + toggleducksdial->update_toggles(m); + + toggleducksdial->signal_ducks_position().connect( + sigc::bind(sigc::mem_fun(*this, &studio::CanvasView::toggle_duck_mask),Duck::TYPE_POSITION) + ); + toggleducksdial->signal_ducks_vertex().connect( + sigc::bind(sigc::mem_fun(*this, &studio::CanvasView::toggle_duck_mask),Duck::TYPE_VERTEX) + ); + toggleducksdial->signal_ducks_tangent().connect( + sigc::bind(sigc::mem_fun(*this, &studio::CanvasView::toggle_duck_mask),Duck::TYPE_TANGENT) + ); + toggleducksdial->signal_ducks_radius().connect( + sigc::bind(sigc::mem_fun(*this, &studio::CanvasView::toggle_duck_mask),Duck::TYPE_RADIUS) + ); + toggleducksdial->signal_ducks_width().connect( + sigc::bind(sigc::mem_fun(*this, &studio::CanvasView::toggle_duck_mask),Duck::TYPE_WIDTH) + ); + toggleducksdial->signal_ducks_angle().connect( + sigc::bind(sigc::mem_fun(*this, &studio::CanvasView::toggle_duck_mask),Duck::TYPE_ANGLE) + ); + toggleducksdial->show(); + + // Set up the ResolutionDial widget + resolutiondial=Gtk::manage(new class ResolutionDial()); + + resolutiondial->update_lowres(work_area->get_low_resolution_flag()); + resolutiondial->signal_increase_resolution().connect( + sigc::mem_fun(*this, &studio::CanvasView::decrease_low_res_pixel_size)); + resolutiondial->signal_decrease_resolution().connect( + sigc::mem_fun(*this, &studio::CanvasView::increase_low_res_pixel_size)); + resolutiondial->signal_use_low_resolution().connect( + sigc::mem_fun(*this, &studio::CanvasView::toggle_low_res_pixel_flag)); + resolutiondial->show(); + + // Set up a separator + Gtk::VSeparator *separator1 = Gtk::manage(new class Gtk::VSeparator()); + separator1->show(); + Gtk::VSeparator *separator2 = Gtk::manage(new class Gtk::VSeparator()); + separator2->show(); + + // Set up quality spin button + quality_spin=Gtk::manage(new class Gtk::SpinButton(quality_adjustment_)); + quality_spin->signal_value_changed().connect( + sigc::mem_fun(*this, &studio::CanvasView::update_quality)); + tooltips.set_tip(*quality_spin, _("Quality (lower is better)")); + quality_spin->show(); + + // Set up the show grid toggle button + show_grid = Gtk::manage(new class Gtk::ToggleButton()); + show_grid->set_active(work_area->grid_status()); + Gtk::Image *icon = manage(new Gtk::Image(Gtk::StockID("synfig-toggle_show_grid"), Gtk::IconSize::from_name("synfig-small_icon"))); + icon->set_padding(0, 0); + icon->show(); + show_grid->add(*icon); + show_grid->signal_toggled().connect( + sigc::mem_fun(*this, &studio::CanvasView::toggle_show_grid)); + tooltips.set_tip(*show_grid, _("Show grid when enabled")); + show_grid->set_relief(Gtk::RELIEF_NONE); + show_grid->show(); + + // Set up the snap to grid toggle button + snap_grid = Gtk::manage(new class Gtk::ToggleButton()); + snap_grid->set_active(work_area->grid_status()); + Gtk::Image *icon2 = manage(new Gtk::Image(Gtk::StockID("synfig-toggle_snap_grid"), Gtk::IconSize::from_name("synfig-small_icon"))); + icon2->set_padding(0, 0); + icon2->show(); + snap_grid->add(*icon2); + snap_grid->signal_toggled().connect( + sigc::mem_fun(*this, &studio::CanvasView::toggle_snap_grid)); + tooltips.set_tip(*snap_grid, _("Snap grid when enabled")); + snap_grid->set_relief(Gtk::RELIEF_NONE); + snap_grid->show(); + + // Set up the onion skin toggle button + onion_skin = Gtk::manage(new class Gtk::ToggleButton()); + onion_skin->set_active(work_area->get_onion_skin()); + Gtk::Image *icon3 = manage(new Gtk::Image(Gtk::StockID("synfig-toggle_onion_skin"), Gtk::IconSize::from_name("synfig-small_icon"))); + icon3->set_padding(0, 0); + icon3->show(); + onion_skin->add(*icon3); + onion_skin->signal_toggled().connect( + sigc::mem_fun(*this, &studio::CanvasView::toggle_onion_skin)); + tooltips.set_tip(*onion_skin, _("Shows onion skin when enabled")); + onion_skin->set_relief(Gtk::RELIEF_NONE); + onion_skin->show(); + + // Set up past onion skin spin button + past_onion_spin=Gtk::manage(new class Gtk::SpinButton(past_onion_adjustment_)); + past_onion_spin->signal_value_changed().connect( + sigc::mem_fun(*this, &studio::CanvasView::set_onion_skins)); + tooltips.set_tip(*past_onion_spin, _("Past onion skins")); + past_onion_spin->show(); + + // Set up future onion skin spin button + future_onion_spin=Gtk::manage(new class Gtk::SpinButton(future_onion_adjustment_)); + future_onion_spin->signal_value_changed().connect( + sigc::mem_fun(*this, &studio::CanvasView::set_onion_skins)); + tooltips.set_tip(*future_onion_spin, _("Future onion skins")); + future_onion_spin->show(); + + + displaybar->attach(*toggleducksdial, 0, 1, 0, 1, Gtk::SHRINK, Gtk::SHRINK); + displaybar->attach(*separator1, 1, 2, 0, 1, Gtk::FILL, Gtk::FILL); + displaybar->attach(*resolutiondial, 2, 3, 0, 1, Gtk::SHRINK, Gtk::SHRINK); + displaybar->attach(*separator2, 3, 4, 0, 1, Gtk::FILL, Gtk::FILL); + displaybar->attach(*quality_spin, 4, 5, 0, 1, Gtk::SHRINK, Gtk::SHRINK); + displaybar->attach(*show_grid, 5, 6, 0, 1, Gtk::SHRINK, Gtk::SHRINK); + displaybar->attach(*snap_grid, 6, 7, 0, 1, Gtk::SHRINK, Gtk::SHRINK); + displaybar->attach(*past_onion_spin, 7, 8, 0, 1, Gtk::SHRINK, Gtk::SHRINK); + displaybar->attach(*onion_skin, 8, 9, 0, 1, Gtk::SHRINK, Gtk::SHRINK); + displaybar->attach(*future_onion_spin, 9, 10, 0, 1, Gtk::SHRINK, Gtk::SHRINK); + + displaybar->show(); + + return displaybar; + +} + void CanvasView::on_current_time_widget_changed() { @@ -1352,7 +1489,7 @@ CanvasView::init_menus() } action_group->add( action, sigc::bind( - sigc::mem_fun(*work_area, &studio::WorkArea::set_quality), + sigc::mem_fun(*this, &studio::CanvasView::set_quality), i ) ); @@ -1403,11 +1540,11 @@ CanvasView::init_menus() grid_show_toggle = Gtk::ToggleAction::create("toggle-grid-show", _("Show Grid")); grid_show_toggle->set_active(work_area->grid_status()); - action_group->add(grid_show_toggle, sigc::mem_fun(*work_area, &studio::WorkArea::toggle_grid)); + action_group->add(grid_show_toggle, sigc::mem_fun(*this, &studio::CanvasView::toggle_show_grid)); grid_snap_toggle = Gtk::ToggleAction::create("toggle-grid-snap", _("Snap to Grid")); grid_snap_toggle->set_active(work_area->get_grid_snap()); - action_group->add(grid_snap_toggle, sigc::mem_fun(*work_area, &studio::WorkArea::toggle_grid_snap)); + action_group->add(grid_snap_toggle, sigc::mem_fun(*this, &studio::CanvasView::toggle_snap_grid)); action = Gtk::ToggleAction::create("toggle-guide-show", _("Show Guides")); action->set_active(work_area->get_show_guides()); @@ -1415,11 +1552,11 @@ CanvasView::init_menus() action = Gtk::ToggleAction::create("toggle-low-res", _("Use Low-Res")); action->set_active(work_area->get_low_resolution_flag()); - action_group->add(action, sigc::mem_fun(*work_area, &studio::WorkArea::toggle_low_resolution_flag)); + action_group->add(action, sigc::mem_fun(*this, &studio::CanvasView::toggle_low_res_pixel_flag)); action = Gtk::ToggleAction::create("toggle-onion-skin", _("Show Onion Skin")); action->set_active(work_area->get_onion_skin()); - action_group->add(action, sigc::mem_fun(*work_area, &studio::WorkArea::toggle_onion_skin)); + action_group->add(action, sigc::mem_fun(*this, &studio::CanvasView::toggle_onion_skin)); } action_group->add( Gtk::Action::create("canvas-zoom-fit", Gtk::StockID("gtk-zoom-fit")), @@ -2750,6 +2887,18 @@ CanvasView::on_duck_changed(const synfig::Point &value,const synfigapp::ValueDes } } + if (ValueNode_Scale::Handle scale_value_node = ValueNode_Scale::Handle::cast_dynamic(value_desc.get_value_node())) + { + int link_index(scale_value_node->get_link_index_from_name("link")); + if(scale_value_node->is_invertible(get_time())) + return canvas_interface()->change_value( + synfigapp::ValueDesc(scale_value_node,link_index), + scale_value_node->get_inverse(get_time(), value) + ); + else + return false; + } + switch(value_desc.get_value_type()) { case ValueBase::TYPE_REAL: @@ -2771,6 +2920,18 @@ CanvasView::on_duck_angle_changed(const synfig::Angle &rotation,const synfigapp: return canvas_interface()->change_value(synfigapp::ValueDesc(bline_tangent,offset_index), old_offset + rotation); } + if (ValueNode_Scale::Handle scale_value_node = ValueNode_Scale::Handle::cast_dynamic(value_desc.get_value_node())) + { + int link_index(scale_value_node->get_link_index_from_name("link")); + if(scale_value_node->is_invertible(get_time())) + return canvas_interface()->change_value( + synfigapp::ValueDesc(scale_value_node,link_index), + scale_value_node->get_inverse(get_time(), rotation) + ); + else + return false; + + } // \todo will this really always be the case? assert(value_desc.get_value_type() == ValueBase::TYPE_ANGLE); return canvas_interface()->change_value(value_desc, value_desc.get_value(get_time()).get(Angle()) + rotation); @@ -3029,9 +3190,11 @@ CanvasView::rebuild_ducks() void CanvasView::decrease_low_res_pixel_size() { + if(changing_resolution_) + return; + changing_resolution_=true; list sizes = CanvasView::get_pixel_sizes(); int pixel_size = work_area->get_low_res_pixel_size(); - for (list::iterator iter = sizes.begin(); iter != sizes.end(); iter++) if (*iter == pixel_size) { @@ -3047,17 +3210,32 @@ CanvasView::decrease_low_res_pixel_size() } break; } + // Update the "toggle-low-res" action + Glib::RefPtr action = Glib::RefPtr::cast_dynamic(action_group->get_action("toggle-low-res")); + action->set_active(work_area->get_low_resolution_flag()); + // Update toggle low res button + resolutiondial->update_lowres(work_area->get_low_resolution_flag()); + changing_resolution_=false; } void CanvasView::increase_low_res_pixel_size() { + if(changing_resolution_) + return; + changing_resolution_=true; list sizes = CanvasView::get_pixel_sizes(); int pixel_size = work_area->get_low_res_pixel_size(); - if (!work_area->get_low_resolution_flag()) { + // We were using "hi res" so change it to low res. work_area->set_low_resolution_flag(true); + // Update the "toggle-low-res" action + Glib::RefPtr action = Glib::RefPtr::cast_dynamic(action_group->get_action("toggle-low-res")); + action->set_active(true); + // Update the toggle low res button + resolutiondial->update_lowres(true); + changing_resolution_=false; return; } @@ -3073,6 +3251,109 @@ CanvasView::increase_low_res_pixel_size() } break; } + // Update the "toggle-low-res" action + Glib::RefPtr action = Glib::RefPtr::cast_dynamic(action_group->get_action("toggle-low-res")); + action->set_active(work_area->get_low_resolution_flag()); + // Update toggle low res button + resolutiondial->update_lowres(work_area->get_low_resolution_flag()); + changing_resolution_=false; +} + +void +CanvasView::toggle_low_res_pixel_flag() +{ + if(changing_resolution_) + return; + changing_resolution_=true; + work_area->toggle_low_resolution_flag(); + // Update the toggle low res button + resolutiondial->update_lowres(work_area->get_low_resolution_flag()); + // Update the "toggle-low-res" action + Glib::RefPtr action = Glib::RefPtr::cast_dynamic(action_group->get_action("toggle-low-res")); + action->set_active(work_area->get_low_resolution_flag()); + changing_resolution_=false; +} + +void +CanvasView::update_quality() +{ + //if(working_depth) + // return; + if(updating_quality_) + return; + updating_quality_=true; + work_area->set_quality((int) quality_spin->get_value()); + // Update Quality Radio actions + Glib::RefPtr action=Glib::RefPtr::cast_dynamic( + action_group->get_action(strprintf("quality-%02d",(int) quality_spin->get_value())) + ); + action->set_active(); + + updating_quality_=false; +} + +void +CanvasView::set_quality(int x) +{ + if(updating_quality_) + return; + work_area->set_quality(x); + // Update the quality spin button + quality_spin->set_value(x); +} + +void +CanvasView::set_onion_skins() +{ + if(toggling_onion_skin) + return; + int onion_skins[2]; + onion_skins[0]=past_onion_spin->get_value(); + onion_skins[1]=future_onion_spin->get_value(); + work_area->set_onion_skins(onion_skins); +} + +void +CanvasView::toggle_show_grid() +{ + if(toggling_show_grid) + return; + toggling_show_grid=true; + work_area->toggle_grid(); + // Update the toggle grid show action + set_grid_show_toggle(work_area->grid_status()); + // Update the toggle grid show check button + show_grid->set_active(work_area->grid_status()); + toggling_show_grid=false; +} + +void +CanvasView::toggle_snap_grid() +{ + if(toggling_snap_grid) + return; + toggling_snap_grid=true; + work_area->toggle_grid_snap(); + // Update the toggle grid snap action + set_grid_snap_toggle(work_area->get_grid_snap()); + // Update the toggle grid snap check button + snap_grid->set_active(work_area->get_grid_snap()); + toggling_snap_grid=false; +} + +void +CanvasView::toggle_onion_skin() +{ + if(toggling_onion_skin) + return; + toggling_onion_skin=true; + work_area->toggle_onion_skin(); + // Update the toggle onion skin action + Glib::RefPtr action = Glib::RefPtr::cast_dynamic(action_group->get_action("toggle-onion-skin")); + action->set_active(work_area->get_onion_skin()); + // Update the toggle grid snap check button + onion_skin->set_active(work_area->get_onion_skin()); + toggling_onion_skin=false; } void @@ -3634,6 +3915,9 @@ CanvasView::on_keyframe_remove_pressed() void CanvasView::toggle_duck_mask(Duckmatic::Type type) { + if(toggling_ducks_) + return; + toggling_ducks_=true; bool is_currently_on(work_area->get_type_mask()&type); if(is_currently_on) @@ -3642,6 +3926,30 @@ CanvasView::toggle_duck_mask(Duckmatic::Type type) work_area->set_type_mask(work_area->get_type_mask()|type); work_area->queue_draw(); + try + { + // Update the toggle ducks actions + Glib::RefPtr action; + action = Glib::RefPtr::cast_dynamic(action_group->get_action("mask-position-ducks")); + action->set_active((bool)(work_area->get_type_mask()&Duck::TYPE_POSITION)); + action = Glib::RefPtr::cast_dynamic(action_group->get_action("mask-tangent-ducks")); + action->set_active((bool)(work_area->get_type_mask()&Duck::TYPE_TANGENT)); + action = Glib::RefPtr::cast_dynamic(action_group->get_action("mask-vertex-ducks")); + action->set_active((bool)(work_area->get_type_mask()&Duck::TYPE_VERTEX)); + action = Glib::RefPtr::cast_dynamic(action_group->get_action("mask-radius-ducks")); + action->set_active((bool)(work_area->get_type_mask()&Duck::TYPE_RADIUS)); + action = Glib::RefPtr::cast_dynamic(action_group->get_action("mask-width-ducks")); + action->set_active((bool)(work_area->get_type_mask()&Duck::TYPE_WIDTH)); + action = Glib::RefPtr::cast_dynamic(action_group->get_action("mask-angle-ducks")); + action->set_active((bool)(work_area->get_type_mask()&Duck::TYPE_ANGLE)); + // Update toggle ducks buttons + toggleducksdial->update_toggles(work_area->get_type_mask()); + } + catch(...) + { + toggling_ducks_=false; + } + toggling_ducks_=false; } void diff --git a/synfig-studio/trunk/src/gtkmm/canvasview.h b/synfig-studio/trunk/src/gtkmm/canvasview.h index 844a57f..a33fb26 100644 --- a/synfig-studio/trunk/src/gtkmm/canvasview.h +++ b/synfig-studio/trunk/src/gtkmm/canvasview.h @@ -7,6 +7,7 @@ ** \legal ** Copyright (c) 2002-2005 Robert B. Quattlebaum Jr., Adrian Bentley ** Copyright (c) 2007, 2008 Chris Moore +** Copyright (c) 2009 Carlos López ** ** This package is free software; you can redistribute it and/or ** modify it under the terms of the GNU General Public License as @@ -41,6 +42,7 @@ #include #include #include +#include #include #include @@ -66,6 +68,8 @@ #include "dialog_waypoint.h" #include "dialog_keyframe.h" #include "framedial.h" +#include "toggleducksdial.h" +#include "resolutiondial.h" #include "duckmatic.h" #include @@ -261,12 +265,28 @@ private: Gtk::Button *refreshbutton; Gtk::Button *treetogglebutton; // not used Gtk::Notebook *notebook; // not used - Gtk::Widget *timebar; + Gtk::Table *timebar; + Gtk::Table *displaybar; Gtk::Button *animatebutton; Gtk::Button *keyframebutton; FrameDial *framedial; - - + ToggleDucksDial *toggleducksdial; + bool toggling_ducks_; + ResolutionDial *resolutiondial; + bool changing_resolution_; + Gtk::Adjustment quality_adjustment_; + Gtk::SpinButton *quality_spin; + Gtk::Adjustment past_onion_adjustment_; + Gtk::SpinButton *past_onion_spin; + Gtk::Adjustment future_onion_adjustment_; + Gtk::SpinButton *future_onion_spin; + bool updating_quality_; + Gtk::ToggleButton *show_grid; + Gtk::ToggleButton *snap_grid; + Gtk::ToggleButton *onion_skin; + bool toggling_show_grid; + bool toggling_snap_grid; + bool toggling_onion_skin; //! Shows current time and allows edition Widget_Time *current_time_widget; void on_current_time_widget_changed(); @@ -405,6 +425,8 @@ private: Gtk::Widget *create_time_bar(); + Gtk::Widget *create_display_bar(); + //! Pop up menu for the bezier (bline, draw) tool (?) void popup_param_menu_bezier(float location, synfigapp::ValueDesc value_desc) { popup_param_menu(value_desc,location,true); } @@ -425,6 +447,12 @@ private: void decrease_low_res_pixel_size(); void increase_low_res_pixel_size(); + void toggle_low_res_pixel_flag(); + void set_quality(int x); + void set_onion_skins(); + void toggle_show_grid(); + void toggle_snap_grid(); + void toggle_onion_skin(); /* -- ** -- P U B L I C M E T H O D S ----------------------------------------- @@ -596,6 +624,10 @@ public: bool is_playing() { return is_playing_; } + void update_quality(); + + + /* -- ** -- S I G N A L T E R M I N A L S ------------------------------------- */ diff --git a/synfig-studio/trunk/src/gtkmm/dialog_setup.cpp b/synfig-studio/trunk/src/gtkmm/dialog_setup.cpp index 9f849b0..89199c9 100644 --- a/synfig-studio/trunk/src/gtkmm/dialog_setup.cpp +++ b/synfig-studio/trunk/src/gtkmm/dialog_setup.cpp @@ -7,7 +7,7 @@ ** \legal ** Copyright (c) 2002-2005 Robert B. Quattlebaum Jr., Adrian Bentley ** Copyright (c) 2007, 2008 Chris Moore -** Copyright (c) 2008 Carlos López +** Copyright (c) 2008, 2009 Carlos López ** ** This package is free software; you can redistribute it and/or ** modify it under the terms of the GNU General Public License as @@ -37,7 +37,6 @@ #include #include #include -#include #include "widget_enum.h" #include "autorecover.h" @@ -84,7 +83,8 @@ Dialog_Setup::Dialog_Setup(): toggle_restrict_radius_ducks(_("Restrict Real-Valued Ducks to Top Right Quadrant")), toggle_resize_imported_images(_("Scale New Imported Images to Fit Canvas")), adj_pref_x_size(480,1,10000,1,10,0), - adj_pref_y_size(270,1,10000,1,10,0) + adj_pref_y_size(270,1,10000,1,10,0), + adj_pref_fps(24.0,1.0,100,0.1,1,0) { // Setup the buttons @@ -219,33 +219,33 @@ Dialog_Setup::Dialog_Setup(): misc_table->attach(textbox_browser_command, 1, 2, 4, 5, Gtk::EXPAND|Gtk::FILL, Gtk::SHRINK|Gtk::FILL, xpadding, ypadding); // Document - Gtk::Table *document_table=manage(new Gtk::Table(2,4,false)); - notebook->append_page(*document_table,_("Document")); + Gtk::Table *document_table = manage(new Gtk::Table(2, 4, false)); + notebook->append_page(*document_table, _("Document")); // Document - Preferred file name prefix attach_label(document_table, _("New Document filename prefix"), 0, xpadding, ypadding); document_table->attach(textbox_custom_filename_prefix, 1, 4, 0, 1, Gtk::EXPAND|Gtk::FILL, Gtk::SHRINK|Gtk::FILL, xpadding, ypadding); - tooltips_.set_tip(textbox_custom_filename_prefix,_("File name prefix for the new created document")); + tooltips_.set_tip(textbox_custom_filename_prefix, _("File name prefix for the new created document")); // Document - New Document X size - Gtk::SpinButton* pref_x_size_spinbutton(manage(new Gtk::SpinButton(adj_pref_x_size,1,0))); - attach_label(document_table,_("New Document X size"),1, xpadding, ypadding); - document_table->attach(*pref_x_size_spinbutton, 1, 2, 1, 2,Gtk::EXPAND|Gtk::FILL, Gtk::SHRINK|Gtk::FILL, xpadding, ypadding); - tooltips_.set_tip(*pref_x_size_spinbutton,_("Width in pixels of the new created document")); + pref_x_size_spinbutton = Gtk::manage(new Gtk::SpinButton(adj_pref_x_size, 1, 0)); + attach_label(document_table, _("New Document X size"),1, xpadding, ypadding); + document_table->attach(*pref_x_size_spinbutton, 1, 2, 1, 2, Gtk::EXPAND|Gtk::FILL, Gtk::SHRINK|Gtk::FILL, xpadding, ypadding); + tooltips_.set_tip(*pref_x_size_spinbutton, _("Width in pixels of the new created document")); // Document - New Document Y size - Gtk::SpinButton* pref_y_size_spinbutton(manage(new Gtk::SpinButton(adj_pref_y_size,1,0))); - attach_label(document_table,_("New Document Y size"),2, xpadding, ypadding); + pref_y_size_spinbutton = Gtk::manage(new Gtk::SpinButton(adj_pref_y_size, 1, 0)); + attach_label(document_table,_("New Document Y size"), 2, xpadding, ypadding); document_table->attach(*pref_y_size_spinbutton, 1, 2, 2, 3,Gtk::EXPAND|Gtk::FILL, Gtk::SHRINK|Gtk::FILL, xpadding, ypadding); - tooltips_.set_tip(*pref_y_size_spinbutton,_("High in pixels of the new created document")); + tooltips_.set_tip(*pref_y_size_spinbutton, _("High in pixels of the new created document")); //Document - Template for predefined sizes of canvases. - size_template_combo=Gtk::manage(new Gtk::ComboBoxText()); + size_template_combo = Gtk::manage(new Gtk::ComboBoxText()); Gtk::Label* label(manage(new Gtk::Label(_("Predefined Resolutions:")))); label->set_alignment(Gtk::ALIGN_LEFT, Gtk::ALIGN_CENTER); document_table->attach(*label, 2, 3, 1, 2, Gtk::SHRINK|Gtk::FILL, Gtk::SHRINK|Gtk::FILL, xpadding, ypadding); - document_table->attach(*size_template_combo,2, 3, 2, 3, Gtk::EXPAND|Gtk::FILL, Gtk::SHRINK|Gtk::FILL, xpadding, ypadding); - size_template_combo->signal_changed().connect(sigc::mem_fun(*this,&studio::Dialog_Setup::on_size_template_combo_change)); + document_table->attach(*size_template_combo, 2, 3, 2, 3, Gtk::EXPAND|Gtk::FILL, Gtk::SHRINK|Gtk::FILL, xpadding, ypadding); + size_template_combo->signal_changed().connect(sigc::mem_fun(*this, &studio::Dialog_Setup::on_size_template_combo_change)); size_template_combo->prepend_text(_("4096x3112 Full Aperture 4K")); size_template_combo->prepend_text(_("2048x1556 Full Aperture Native 2K")); size_template_combo->prepend_text(_("1920x1080 HDTV 1080p/i")); @@ -262,6 +262,34 @@ Dialog_Setup::Dialog_Setup(): size_template_combo->prepend_text(_("360x203 Web 360x HD")); size_template_combo->prepend_text(DEFAULT_PREDEFINED_SIZE); + //Document - Template for predefined fps + fps_template_combo = Gtk::manage(new Gtk::ComboBoxText()); + Gtk::Label* label1(manage(new Gtk::Label(_("Predefined FPS:")))); + label1->set_alignment(Gtk::ALIGN_LEFT, Gtk::ALIGN_CENTER); + document_table->attach(*label1, 2, 3, 3, 4, Gtk::SHRINK|Gtk::FILL, Gtk::SHRINK|Gtk::FILL, xpadding, ypadding); + document_table->attach(*fps_template_combo,2, 3, 4, 5, Gtk::EXPAND|Gtk::FILL, Gtk::SHRINK|Gtk::FILL, xpadding, ypadding); + fps_template_combo->signal_changed().connect(sigc::mem_fun(*this, &studio::Dialog_Setup::on_fps_template_combo_change)); + //Document - Fill the FPS combo box with proper strings (not localised) + float f[8]; + f[0] = 60; + f[1] = 50; + f[2] = 30; + f[3] = 25; + f[4] = 24.967; + f[5] = 24; + f[6] = 15; + f[7] = 12; + for (int i=0; i<8; i++) + fps_template_combo->prepend_text(strprintf("%5.3f", f[i])); + + fps_template_combo->prepend_text(DEFAULT_PREDEFINED_FPS); + + // Document - New Document FPS + pref_fps_spinbutton = Gtk::manage(new Gtk::SpinButton(adj_pref_fps, 1, 3)); + attach_label(document_table,_("New Document FPS"), 4, xpadding, ypadding); + document_table->attach(*pref_fps_spinbutton, 1, 2, 4, 5, Gtk::EXPAND|Gtk::FILL, Gtk::SHRINK|Gtk::FILL, xpadding, ypadding); + tooltips_.set_tip(*pref_fps_spinbutton, _("Frames per second of the new created document")); + show_all_children(); } @@ -320,6 +348,12 @@ Dialog_Setup::on_apply_pressed() // Set the preferred Predefined size App::predefined_size=size_template_combo->get_active_text(); + // Set the preferred Predefined fps + App::predefined_fps=fps_template_combo->get_active_text(); + + // Set the preferred FPS + App::preferred_fps=Real(adj_pref_fps.get_value()); + App::save_settings(); } @@ -369,6 +403,8 @@ Dialog_Setup::on_size_template_combo_change() String selection(size_template_combo->get_active_text()); if(selection==DEFAULT_PREDEFINED_SIZE) { + pref_y_size_spinbutton->set_sensitive(true); + pref_x_size_spinbutton->set_sensitive(true); return; } String::size_type locx=selection.find_first_of("x"); // here should be some comparison with string::npos @@ -379,6 +415,23 @@ Dialog_Setup::on_size_template_combo_change() int y=atoi(y_size.c_str()); adj_pref_x_size.set_value(x); adj_pref_y_size.set_value(y); + pref_y_size_spinbutton->set_sensitive(false); + pref_x_size_spinbutton->set_sensitive(false); + + return; +} + +void +Dialog_Setup::on_fps_template_combo_change() +{ + String selection(fps_template_combo->get_active_text()); + if(selection==DEFAULT_PREDEFINED_FPS) + { + pref_fps_spinbutton->set_sensitive(true); + return; + } + adj_pref_fps.set_value(atof(selection.c_str())); + pref_fps_spinbutton->set_sensitive(false); return; } @@ -439,6 +492,12 @@ Dialog_Setup::refresh() // Refresh the preferred Predefined size size_template_combo->set_active_text(App::predefined_size); + + //Refresh the preferred FPS + adj_pref_fps.set_value(App::preferred_fps); + + //Refresh the predefined FPS + fps_template_combo->set_active_text(App::predefined_fps); } GammaPattern::GammaPattern(): diff --git a/synfig-studio/trunk/src/gtkmm/dialog_setup.h b/synfig-studio/trunk/src/gtkmm/dialog_setup.h index e0d8fcd..530e4fa 100644 --- a/synfig-studio/trunk/src/gtkmm/dialog_setup.h +++ b/synfig-studio/trunk/src/gtkmm/dialog_setup.h @@ -7,7 +7,7 @@ ** \legal ** Copyright (c) 2002-2005 Robert B. Quattlebaum Jr., Adrian Bentley ** Copyright (c) 2007, 2008 Chris Moore -** Copyright (c) 2008 Carlos López +** Copyright (c) 2008, 2009 Carlos López ** ** This package is free software; you can redistribute it and/or ** modify it under the terms of the GNU General Public License as @@ -40,6 +40,7 @@ #include #include #include +#include #include #include @@ -49,6 +50,10 @@ #ifndef DEFAULT_PREDEFINED_SIZE #define DEFAULT_PREDEFINED_SIZE _("Custom Size") #endif +#ifndef DEFAULT_PREDEFINED_FPS +#define DEFAULT_PREDEFINED_FPS _("Custom fps") +#endif + /* === T Y P E D E F S ===================================================== */ /* === C L A S S E S & S T R U C T S ======================================= */ @@ -156,6 +161,7 @@ class Dialog_Setup : public Gtk::Dialog void on_black_level_change(); void on_red_blue_level_change(); void on_size_template_combo_change(); + void on_fps_template_combo_change(); GammaPattern gamma_pattern; BlackLevelSelector black_level_selector; @@ -187,9 +193,14 @@ class Dialog_Setup : public Gtk::Dialog Gtk::Entry textbox_browser_command; Gtk::ComboBoxText* size_template_combo; + Gtk::ComboBoxText* fps_template_combo; Gtk::Entry textbox_custom_filename_prefix; Gtk::Adjustment adj_pref_x_size; Gtk::Adjustment adj_pref_y_size; + Gtk::Adjustment adj_pref_fps; + Gtk::SpinButton* pref_fps_spinbutton; + Gtk::SpinButton* pref_y_size_spinbutton; + Gtk::SpinButton* pref_x_size_spinbutton; Gtk::Tooltips tooltips_; public: diff --git a/synfig-studio/trunk/src/gtkmm/framedial.cpp b/synfig-studio/trunk/src/gtkmm/framedial.cpp index 0392f4b..6437930 100644 --- a/synfig-studio/trunk/src/gtkmm/framedial.cpp +++ b/synfig-studio/trunk/src/gtkmm/framedial.cpp @@ -6,7 +6,9 @@ ** ** \legal ** Copyright (c) 2002-2005 Robert B. Quattlebaum Jr., Adrian Bentley +** Copyright (c) 2008 Chris Moore ** Copyright (c) 2009 Gerco Ballintijn +** Copyright (c) 2009 Carlos López ** ** This package is free software; you can redistribute it and/or ** modify it under the terms of the GNU General Public License as diff --git a/synfig-studio/trunk/src/gtkmm/framedial.h b/synfig-studio/trunk/src/gtkmm/framedial.h index 89dfac3..4fc51ca 100644 --- a/synfig-studio/trunk/src/gtkmm/framedial.h +++ b/synfig-studio/trunk/src/gtkmm/framedial.h @@ -8,6 +8,7 @@ ** Copyright (c) 2002-2005 Robert B. Quattlebaum Jr., Adrian Bentley ** Copyright (c) 2008 Chris Moore ** Copyright (c) 2009 Gerco Ballintijn +** Copyright (c) 2009 Carlos López ** ** This package is free software; you can redistribute it and/or ** modify it under the terms of the GNU General Public License as diff --git a/synfig-studio/trunk/src/gtkmm/iconcontroller.cpp b/synfig-studio/trunk/src/gtkmm/iconcontroller.cpp index 32d3001..8af9357 100644 --- a/synfig-studio/trunk/src/gtkmm/iconcontroller.cpp +++ b/synfig-studio/trunk/src/gtkmm/iconcontroller.cpp @@ -8,6 +8,8 @@ ** Copyright (c) 2002-2005 Robert B. Quattlebaum Jr., Adrian Bentley ** Copyright (c) 2007, 2008 Chris Moore ** Copyright (c) 2008 Paul Wise +** Copyright (c) 2009 Gerco Ballintijn +** Copyright (c) 2009 Carlos López ** ** This package is free software; you can redistribute it and/or ** modify it under the terms of the GNU General Public License as @@ -193,6 +195,18 @@ IconController::IconController(const synfig::String& /*basepath*/) INIT_STOCK_ICON(seek_next_frame,"seek_next_frame."IMAGE_EXT,_("Next Frame")); INIT_STOCK_ICON(seek_end,"seek_end."IMAGE_EXT,_("Seek to End")); + INIT_STOCK_ICON(toggle_duck_position,"duck_position_icon."IMAGE_EXT,_("Toogle position ducks")); + INIT_STOCK_ICON(toggle_duck_vertex,"duck_vertex_icon."IMAGE_EXT,_("Toogle vertex ducks")); + INIT_STOCK_ICON(toggle_duck_tangent,"duck_tangent_icon."IMAGE_EXT,_("Toogle tangent ducks")); + INIT_STOCK_ICON(toggle_duck_radius,"duck_radius_icon."IMAGE_EXT,_("Toogle radius ducks")); + INIT_STOCK_ICON(toggle_duck_width,"duck_width_icon."IMAGE_EXT,_("Toogle width ducks")); + INIT_STOCK_ICON(toggle_duck_angle,"duck_angle_icon."IMAGE_EXT,_("Toogle angle ducks")); + + INIT_STOCK_ICON(toggle_show_grid,"show_grid_icon."IMAGE_EXT,_("Toggle show grid")); + INIT_STOCK_ICON(toggle_snap_grid,"snap_grid_icon."IMAGE_EXT,_("Toggle snap grid")); + + INIT_STOCK_ICON(toggle_onion_skin,"onion_skin_icon."IMAGE_EXT,_("Toggle onion skin")); + INIT_STOCK_ICON_CLONE(cvs_add,"gtk-add",_("CVS Add")); INIT_STOCK_ICON_CLONE(cvs_update,"gtk-open",_("CVS Update")); INIT_STOCK_ICON_CLONE(cvs_commit,"gtk-save",_("CVS Commit")); diff --git a/synfig-studio/trunk/src/gtkmm/keyframedial.cpp b/synfig-studio/trunk/src/gtkmm/keyframedial.cpp index a9bf328..c7b5c56 100644 --- a/synfig-studio/trunk/src/gtkmm/keyframedial.cpp +++ b/synfig-studio/trunk/src/gtkmm/keyframedial.cpp @@ -33,6 +33,7 @@ #include "keyframedial.h" #include +#include #endif @@ -53,8 +54,8 @@ KeyFrameDial::KeyFrameDial(): Gtk::Table(1, 3, false) { Gtk::IconSize iconsize = Gtk::IconSize::from_name("synfig-small_icon"); - seek_prev_keyframe = create_icon(iconsize, GTK_STOCK_GO_BACK, _("Previous KeyFrame")); - seek_next_keyframe = create_icon(iconsize, GTK_STOCK_GO_FORWARD, _("Next KeyFrame")); + seek_prev_keyframe = create_icon(iconsize, Gtk::Stock::GO_BACK, _("Previous KeyFrame")); + seek_next_keyframe = create_icon(iconsize, Gtk::Stock::GO_FORWARD, _("Next KeyFrame")); lock_keyframe = create_icon(Gtk::ICON_SIZE_BUTTON, "synfig-keyframe_lock_all",_("All Keyframes Locked")); attach(*seek_prev_keyframe, 0, 1, 0, 1, Gtk::SHRINK, Gtk::SHRINK, 0, 0); @@ -77,3 +78,19 @@ KeyFrameDial::create_icon(Gtk::IconSize iconsize, const char * stockid, return button; } + +Gtk::Button * +KeyFrameDial::create_icon(Gtk::IconSize iconsize, const Gtk::BuiltinStockID & stockid, + const char * tooltip) +{ + Gtk::Button *button = manage(new class Gtk::Button()); + Gtk::Image *icon = manage(new Gtk::Image(stockid, iconsize)); + button->add(*icon); + tooltips.set_tip(*button, tooltip); + icon->set_padding(0, 0); + icon->show(); + button->set_relief(Gtk::RELIEF_NONE); + button->show(); + + return button; +} diff --git a/synfig-studio/trunk/src/gtkmm/keyframedial.h b/synfig-studio/trunk/src/gtkmm/keyframedial.h index 41dfc57..a6491c9 100644 --- a/synfig-studio/trunk/src/gtkmm/keyframedial.h +++ b/synfig-studio/trunk/src/gtkmm/keyframedial.h @@ -54,6 +54,7 @@ class KeyFrameDial : public Gtk::Table Gtk::Button *lock_keyframe; Gtk::Button *create_icon(Gtk::IconSize iconsize, const char * stockid, const char * tooltip); + Gtk::Button *create_icon(Gtk::IconSize iconsize, const Gtk::BuiltinStockID & stockid, const char * tooltip); public: diff --git a/synfig-studio/trunk/src/gtkmm/render.cpp b/synfig-studio/trunk/src/gtkmm/render.cpp index 4696a47..cec4215 100644 --- a/synfig-studio/trunk/src/gtkmm/render.cpp +++ b/synfig-studio/trunk/src/gtkmm/render.cpp @@ -40,6 +40,8 @@ #include "general.h" +#include + #endif /* === U S I N G =========================================================== */ @@ -287,6 +289,14 @@ RenderSettings::on_render_pressed() canvas_interface_->get_ui_interface()->error(_("Unable to create target for ")+filename); return; } + // This is the only way I've found to avoid send a non writable + // filename path to the renderer. + fstream filetest (filename.c_str(), fstream::out); + if (filetest.fail()) + { + canvas_interface_->get_ui_interface()->error(_("Unable to create file for ")+filename); + return; + } hide(); diff --git a/synfig-studio/trunk/src/gtkmm/resolutiondial.cpp b/synfig-studio/trunk/src/gtkmm/resolutiondial.cpp new file mode 100644 index 0000000..5680f62 --- /dev/null +++ b/synfig-studio/trunk/src/gtkmm/resolutiondial.cpp @@ -0,0 +1,97 @@ +/* === S Y N F I G ========================================================= */ +/*! \file resolutiondial.cpp +** \brief Template File +** +** $Id$ +** +** \legal +** Copyright (c) 2002-2005 Robert B. Quattlebaum Jr., Adrian Bentley +** Copyright (c) 2009 Gerco Ballintijn +** Copyright (c) 2009 Carlos Lopez +** +** This package is free software; you can redistribute it and/or +** modify it under the terms of the GNU General Public License as +** published by the Free Software Foundation; either version 2 of +** the License, or (at your option) any later version. +** +** This package is distributed in the hope that it will be useful, +** but WITHOUT ANY WARRANTY; without even the implied warranty of +** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +** General Public License for more details. +** \endlegal +*/ +/* ========================================================================= */ + +/* === H E A D E R S ======================================================= */ + +#ifdef USING_PCH +# include "pch.h" +#else +#ifdef HAVE_CONFIG_H +# include +#endif + +#include "resolutiondial.h" +#include +#include + +#endif + +/* === U S I N G =========================================================== */ + +using namespace std; +using namespace studio; + +/* === M A C R O S ========================================================= */ + +/* === G L O B A L S ======================================================= */ + +/* === P R O C E D U R E S ================================================= */ + +/* === M E T H O D S ======================================================= */ + +ResolutionDial::ResolutionDial(): Gtk::Table(1, 3, false) +{ + Gtk::IconSize iconsize = Gtk::IconSize::from_name("synfig-small_icon"); + + increase_resolution = create_icon(iconsize, Gtk::Stock::ADD, _("Increase Display Resolution")); + decrease_resolution = create_icon(iconsize, Gtk::Stock::REMOVE, _("Decrease Display Resolution")); + use_low_resolution = create_check(_("Low Res"), _("Use Low Resolution when enabled")); + + attach(*decrease_resolution, 0, 1, 0, 1, Gtk::SHRINK, Gtk::SHRINK, 0, 0); + attach(*use_low_resolution, 1, 2, 0, 1, Gtk::SHRINK, Gtk::SHRINK, 0, 0); + attach(*increase_resolution, 2, 3, 0, 1, Gtk::SHRINK, Gtk::SHRINK, 0, 0); +} + +Gtk::Button * +ResolutionDial::create_icon(Gtk::IconSize size, const Gtk::BuiltinStockID & stockid, + const char * tooltip) +{ + Gtk::Button *button = manage(new class Gtk::Button()); + Gtk::Image *icon = manage(new Gtk::Image(stockid, size)); + button->add(*icon); + tooltips.set_tip(*button, tooltip); + icon->set_padding(0, 0); + icon->show(); + button->set_relief(Gtk::RELIEF_NONE); + button->show(); + + return button; +} + +Gtk::CheckButton * +ResolutionDial::create_check(const char *label, const char * tooltip) +{ + Gtk::CheckButton *cbutton = manage(new class Gtk::CheckButton()); + cbutton->set_label(label); + tooltips.set_tip(*cbutton, tooltip); + cbutton->show(); + + return cbutton; +} + +void +ResolutionDial::update_lowres(bool flag) +{ + use_low_resolution->set_active(flag); +} diff --git a/synfig-studio/trunk/src/gtkmm/resolutiondial.h b/synfig-studio/trunk/src/gtkmm/resolutiondial.h new file mode 100644 index 0000000..5ee9df9 --- /dev/null +++ b/synfig-studio/trunk/src/gtkmm/resolutiondial.h @@ -0,0 +1,77 @@ +/* === S Y N F I G ========================================================= */ +/*! \file resolutiondial.h +** \brief Template Header +** +** $Id$ +** +** \legal +** Copyright (c) 2002-2005 Robert B. Quattlebaum Jr., Adrian Bentley +** Copyright (c) 2008 Chris Moore +** Copyright (c) 2009 Gerco Ballintijn +** Copyright (c) 2009 Carlos Lopez +** +** This package is free software; you can redistribute it and/or +** modify it under the terms of the GNU General Public License as +** published by the Free Software Foundation; either version 2 of +** the License, or (at your option) any later version. +** +** This package is distributed in the hope that it will be useful, +** but WITHOUT ANY WARRANTY; without even the implied warranty of +** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +** General Public License for more details. +** \endlegal +*/ +/* ========================================================================= */ + +/* === S T A R T =========================================================== */ + +#ifndef __SYNFIG_STUDIO_RESOLUTIONDIAL_H +#define __SYNFIG_STUDIO_RESOLUTIONDIAL_H + +/* === H E A D E R S ======================================================= */ + +#include +#include +#include +#include "duckmatic.h" + +#include "general.h" + + +/* === M A C R O S ========================================================= */ + +/* === T Y P E D E F S ===================================================== */ + +/* === C L A S S E S & S T R U C T S ======================================= */ + +namespace studio +{ + +class ResolutionDial : public Gtk::Table +{ + Gtk::Tooltips tooltips; + + Gtk::Button *increase_resolution; + Gtk::Button *decrease_resolution; + Gtk::CheckButton *use_low_resolution; + + Gtk::Button *create_icon(Gtk::IconSize size, const Gtk::BuiltinStockID & stockid, const char * tooltip); + Gtk::CheckButton *create_check(const char *text, const char *tooltip); + +public: + + ResolutionDial(); + + void update_lowres(bool flag); + Glib::SignalProxy0 signal_increase_resolution() { return increase_resolution->signal_clicked(); } + Glib::SignalProxy0 signal_decrease_resolution() { return decrease_resolution->signal_clicked(); } + Glib::SignalProxy0 signal_use_low_resolution() { return use_low_resolution-> signal_toggled(); } + +}; // END of class ResolutionDial + +}; // END of namespace studio + + +/* === E N D =============================================================== */ + +#endif diff --git a/synfig-studio/trunk/src/gtkmm/toggleducksdial.cpp b/synfig-studio/trunk/src/gtkmm/toggleducksdial.cpp new file mode 100644 index 0000000..3f1230a --- /dev/null +++ b/synfig-studio/trunk/src/gtkmm/toggleducksdial.cpp @@ -0,0 +1,97 @@ +/* === S Y N F I G ========================================================= */ +/*! \file toggleducksdial.cpp +** \brief Template File +** +** $Id$ +** +** \legal +** Copyright (c) 2002-2005 Robert B. Quattlebaum Jr., Adrian Bentley +** Copyright (c) 2009 Gerco Ballintijn +** Copyright (c) 2009 Carlos Lopez +** +** This package is free software; you can redistribute it and/or +** modify it under the terms of the GNU General Public License as +** published by the Free Software Foundation; either version 2 of +** the License, or (at your option) any later version. +** +** This package is distributed in the hope that it will be useful, +** but WITHOUT ANY WARRANTY; without even the implied warranty of +** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +** General Public License for more details. +** \endlegal +*/ +/* ========================================================================= */ + +/* === H E A D E R S ======================================================= */ + +#ifdef USING_PCH +# include "pch.h" +#else +#ifdef HAVE_CONFIG_H +# include +#endif + +#include "toggleducksdial.h" +#include +#include + +#endif + +/* === U S I N G =========================================================== */ + +using namespace std; +using namespace studio; + +/* === M A C R O S ========================================================= */ + +/* === G L O B A L S ======================================================= */ + +/* === P R O C E D U R E S ================================================= */ + +/* === M E T H O D S ======================================================= */ + +ToggleDucksDial::ToggleDucksDial(): Gtk::Table(1, 6, false) +{ + Gtk::IconSize iconsize = Gtk::IconSize::from_name("synfig-small_icon"); + + ducks_position = create_label_button(iconsize, "synfig-toggle_duck_position", _("Toogle position ducks")); + ducks_vertex = create_label_button(iconsize, "synfig-toggle_duck_vertex", _("Toogle vertex ducks")); + ducks_tangent = create_label_button(iconsize, "synfig-toggle_duck_tangent", _("Toogle tangent ducks")); + ducks_radius = create_label_button(iconsize, "synfig-toggle_duck_radius", _("Toogle radius ducks")); + ducks_width = create_label_button(iconsize, "synfig-toggle_duck_width", _("Toogle width ducks")); + ducks_angle = create_label_button(iconsize, "synfig-toggle_duck_angle", _("Toogle angle ducks")); + + attach(*ducks_position, 0, 1, 0, 1, Gtk::SHRINK, Gtk::SHRINK, 0, 0); + attach(*ducks_vertex, 1, 2, 0, 1, Gtk::SHRINK, Gtk::SHRINK, 0, 0); + attach(*ducks_tangent, 2, 3, 0, 1, Gtk::SHRINK, Gtk::SHRINK, 0, 0); + attach(*ducks_radius, 3, 4, 0, 1, Gtk::SHRINK, Gtk::SHRINK, 0, 0); + attach(*ducks_width, 4, 5, 0, 1, Gtk::SHRINK, Gtk::SHRINK, 0, 0); + attach(*ducks_angle, 5, 6, 0, 1, Gtk::SHRINK, Gtk::SHRINK, 0, 0); +} + +Gtk::ToggleButton * +ToggleDucksDial::create_label_button(Gtk::IconSize iconsize, const char *stockid, + const char * tooltip) +{ + Gtk::ToggleButton *tbutton = manage(new class Gtk::ToggleButton()); + Gtk::Image *icon = manage(new Gtk::Image(Gtk::StockID(stockid), iconsize)); + tooltips.set_tip(*tbutton, tooltip); + tbutton->add(*icon); + icon->set_padding(0, 0); + icon->show(); + tbutton->set_relief(Gtk::RELIEF_NONE); + tbutton->show(); + + return tbutton; +} + +void +ToggleDucksDial::update_toggles(Duck::Type mask) +{ + ducks_position-> set_active((mask & Duck::TYPE_POSITION)); + ducks_vertex -> set_active((mask & Duck::TYPE_VERTEX)); + ducks_tangent -> set_active((mask & Duck::TYPE_TANGENT)); + ducks_radius -> set_active((mask & Duck::TYPE_RADIUS)); + ducks_width -> set_active((mask & Duck::TYPE_WIDTH)); + ducks_angle -> set_active((mask & Duck::TYPE_ANGLE)); +} diff --git a/synfig-studio/trunk/src/gtkmm/toggleducksdial.h b/synfig-studio/trunk/src/gtkmm/toggleducksdial.h new file mode 100644 index 0000000..d02cdea --- /dev/null +++ b/synfig-studio/trunk/src/gtkmm/toggleducksdial.h @@ -0,0 +1,81 @@ +/* === S Y N F I G ========================================================= */ +/*! \file toggleducksdial.h +** \brief Template Header +** +** $Id$ +** +** \legal +** Copyright (c) 2002-2005 Robert B. Quattlebaum Jr., Adrian Bentley +** Copyright (c) 2008 Chris Moore +** Copyright (c) 2009 Gerco Ballintijn +** Copyright (c) 2009 Carlos Lopez +** +** This package is free software; you can redistribute it and/or +** modify it under the terms of the GNU General Public License as +** published by the Free Software Foundation; either version 2 of +** the License, or (at your option) any later version. +** +** This package is distributed in the hope that it will be useful, +** but WITHOUT ANY WARRANTY; without even the implied warranty of +** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +** General Public License for more details. +** \endlegal +*/ +/* ========================================================================= */ + +/* === S T A R T =========================================================== */ + +#ifndef __SYNFIG_STUDIO_TOOGLEDUCKSDIAL_H +#define __SYNFIG_STUDIO_TOOGLEDUCKSDIAL_H + +/* === H E A D E R S ======================================================= */ + +#include +#include +#include +#include "duckmatic.h" + +#include "general.h" + + +/* === M A C R O S ========================================================= */ + +/* === T Y P E D E F S ===================================================== */ + +/* === C L A S S E S & S T R U C T S ======================================= */ + +namespace studio +{ + +class ToggleDucksDial : public Gtk::Table +{ + Gtk::Tooltips tooltips; + + Gtk::ToggleButton *ducks_position; + Gtk::ToggleButton *ducks_vertex; + Gtk::ToggleButton *ducks_tangent; + Gtk::ToggleButton *ducks_radius; + Gtk::ToggleButton *ducks_width; + Gtk::ToggleButton *ducks_angle; + + Gtk::ToggleButton *create_label_button(Gtk::IconSize iconsize, const char * stockid, const char * tooltip); + +public: + + ToggleDucksDial(); + void update_toggles(Duck::Type mask); + Glib::SignalProxy0 signal_ducks_position() { return ducks_position->signal_toggled(); } + Glib::SignalProxy0 signal_ducks_vertex() { return ducks_vertex-> signal_toggled(); } + Glib::SignalProxy0 signal_ducks_tangent() { return ducks_tangent-> signal_toggled(); } + Glib::SignalProxy0 signal_ducks_radius() { return ducks_radius-> signal_toggled(); } + Glib::SignalProxy0 signal_ducks_width() { return ducks_width-> signal_toggled(); } + Glib::SignalProxy0 signal_ducks_angle() { return ducks_angle-> signal_toggled(); } + +}; // END of class ToggleDucksDial + +}; // END of namespace studio + + +/* === E N D =============================================================== */ + +#endif diff --git a/synfig-studio/trunk/src/gtkmm/workarea.cpp b/synfig-studio/trunk/src/gtkmm/workarea.cpp index 0ebd729..edc989d 100644 --- a/synfig-studio/trunk/src/gtkmm/workarea.cpp +++ b/synfig-studio/trunk/src/gtkmm/workarea.cpp @@ -117,7 +117,7 @@ public: synfig::Mutex mutex; - void set_onion_skin(bool x) + void set_onion_skin(bool x, int *onions) { onionskin=x; @@ -126,26 +126,29 @@ public: if(!onionskin) return; onion_skin_queue.push_back(time); - //onion_skin_queue.push_back(time-1); - //onion_skin_queue.push_back(time+1); + try { - onion_skin_queue.push_back( - get_canvas()->keyframe_list().find_prev( - time - )->get_time() - ); + Time thistime=time; + for(int i=0; ikeyframe_list().find_prev(thistime)->get_time(); + onion_skin_queue.push_back(keytime); + thistime=keytime; + } } catch(...) { } try { - onion_skin_queue.push_back( - get_canvas()->keyframe_list().find_next( - time - )->get_time() - ); + Time thistime=time; + for(int i=0; ikeyframe_list().find_next(thistime)->get_time(); + onion_skin_queue.push_back(keytime); + thistime=keytime; + } } catch(...) { } @@ -414,7 +417,7 @@ public: std::list onion_skin_queue; - void set_onion_skin(bool x) + void set_onion_skin(bool x, int *onions) { onionskin=x; @@ -427,22 +430,26 @@ public: //onion_skin_queue.push_back(time+1); try { - onion_skin_queue.push_back( - get_canvas()->keyframe_list().find_prev( - time - )->get_time() - ); + Time thistime=time; + for(int i=0; ikeyframe_list().find_prev(thistime)->get_time(); + onion_skin_queue.push_back(keytime); + thistime=keytime; + } } catch(...) { } try { - onion_skin_queue.push_back( - get_canvas()->keyframe_list().find_next( - time - )->get_time() - ); + Time thistime=time; + for(int i=0; ikeyframe_list().find_next(thistime)->get_time(); + onion_skin_queue.push_back(keytime); + thistime=keytime; + } } catch(...) { } @@ -672,6 +679,8 @@ WorkArea::WorkArea(etl::loose_handle canvas_interfac ph=0.001; last_focus_point=Point(0,0); onion_skin=false; + onion_skins[0]=0; + onion_skins[1]=0; queued=false; dirty_trap_enabled=false; solid_lines=true; @@ -1019,6 +1028,14 @@ WorkArea::get_onion_skin()const return onion_skin; } +void WorkArea::set_onion_skins(int *onions) +{ + onion_skins[0]=onions[0]; + onion_skins[1]=onions[1]; + if(onion_skin) + queue_render_preview(); +} + void WorkArea::enable_grid() { @@ -2289,7 +2306,7 @@ studio::WorkArea::async_update_preview() handle trgt(new class WorkAreaTarget(this,w,h)); trgt->set_rend_desc(&desc); - trgt->set_onion_skin(get_onion_skin()); + trgt->set_onion_skin(get_onion_skin(), onion_skins); target=trgt; } else @@ -2298,7 +2315,7 @@ studio::WorkArea::async_update_preview() handle trgt(new class WorkAreaTarget_Full(this,w,h)); trgt->set_rend_desc(&desc); - trgt->set_onion_skin(get_onion_skin()); + trgt->set_onion_skin(get_onion_skin(), onion_skins); target=trgt; } diff --git a/synfig-studio/trunk/src/gtkmm/workarea.h b/synfig-studio/trunk/src/gtkmm/workarea.h index 6e5ab7f..989ac8d 100644 --- a/synfig-studio/trunk/src/gtkmm/workarea.h +++ b/synfig-studio/trunk/src/gtkmm/workarea.h @@ -235,6 +235,8 @@ private: bool onion_skin; + //! stores the future [1] and past [0] onion skins based on keyframes + int onion_skins[2]; etl::loose_handle selected_value_node_; @@ -348,6 +350,7 @@ public: void set_onion_skin(bool x); bool get_onion_skin()const; void toggle_onion_skin() { set_onion_skin(!get_onion_skin()); } + void set_onion_skins(int *onions); void set_selected_value_node(etl::loose_handle x); diff --git a/synfig-studio/trunk/src/synfigapp/instance.cpp b/synfig-studio/trunk/src/synfigapp/instance.cpp index 020d337..c3c542b 100644 --- a/synfig-studio/trunk/src/synfigapp/instance.cpp +++ b/synfig-studio/trunk/src/synfigapp/instance.cpp @@ -42,6 +42,7 @@ #include #include #include +#include #include #include "general.h" @@ -74,6 +75,7 @@ synfigapp::is_editable(synfig::ValueNode::Handle value_node) || ValueNode_BLineCalcVertex::Handle::cast_dynamic(value_node) || ValueNode_BLineCalcTangent::Handle::cast_dynamic(value_node) || ValueNode_BLineCalcWidth::Handle::cast_dynamic(value_node) + || ValueNode_Scale::Handle::cast_dynamic(value_node) ) return true; return false;