totalSize = seekDouble(fd, totalSize); // bar_width
end
+ totalSize = seekMatrix(fd, totalSize); // datatips
+
[totalSize, state] = readString(fd, totalSize); // clip_state
if state == "on" then
totalSize = seekDoubleCount(fd, 4, totalSize); //clip_box
#define __GO_Y_SHIFT__ "YShift"
#define __GO_Z_SHIFT__ "ZShift"
#define __GO_BAR_WIDTH__ "BarWidth"
+#define __GO_DATATIPS__ "Datatips"
+#define __GO_DATATIPS_SIZE__ "DatatipsSize"
#define __GO_SURFACE_MODE__ "SurfaceMode"
#define __GO_COLOR_MODE__ "ColorMode"
public static final String __GO_Y_SHIFT__ = "YShift";
public static final String __GO_Z_SHIFT__ = "ZShift";
public static final String __GO_BAR_WIDTH__ = "BarWidth";
+ public static final String __GO_DATATIPS__ = "Datatips";
+ public static final String __GO_DATATIPS_SIZE__ = "DatatipsSize";
public static final String __GO_SURFACE_MODE__ = "SurfaceMode";
public static final String __GO_COLOR_MODE__ = "ColorMode";
/** Polyline properties names */
private enum PolylineProperty { CLOSED, ARROWSIZEFACTOR, POLYLINESTYLE,
INTERPCOLORVECTOR, INTERPCOLORVECTORSET, INTERPCOLORMODE,
- XSHIFT, YSHIFT, ZSHIFT, BARWIDTH };
+ XSHIFT, YSHIFT, ZSHIFT, BARWIDTH, DATATIPS, DATATIPSSIZE };
/** Specifies whether the polyline is closed */
private boolean closed;
/** Bar width */
private double barWidth;
+ /** Datatips property */
+ private Double[] datatips;
+
/** Constructor */
public Polyline() {
super();
yShift = null;
zShift = null;
barWidth = 0.0;
+ datatips = new Double[0];
}
@Override
return PolylineProperty.ZSHIFT;
} else if (propertyName.equals(__GO_BAR_WIDTH__)) {
return PolylineProperty.BARWIDTH;
- } else {
+ } else if (propertyName.equals(__GO_DATATIPS__)) {
+ return PolylineProperty.DATATIPS;
+ } else if (propertyName.equals(__GO_DATATIPS_SIZE__)) {
+ return PolylineProperty.DATATIPSSIZE;
+ } else {
return super.getPropertyFromName(propertyName);
}
}
return getZShift();
} else if (property == PolylineProperty.BARWIDTH) {
return getBarWidth();
- } else {
+ } else if (property == PolylineProperty.DATATIPS) {
+ return getDatatips();
+ } else if (property == PolylineProperty.DATATIPSSIZE) {
+ return getDatatipsSize();
+ } else {
return super.getProperty(property);
}
}
setZShift((double[]) value);
} else if (property == PolylineProperty.BARWIDTH) {
setBarWidth((Double) value);
- } else {
+ } else if (property == PolylineProperty.DATATIPS) {
+ setDatatips((Double[]) value);
+ } else {
return super.setProperty(property, value);
}
zShift = shift;
}
+ /**
+ * @param datatips datatips coordinates
+ */
+ public void setDatatips(Double[] datatips) {
+ this.datatips = datatips;
+ }
+
+ /**
+ * @return the datatips coordinates
+ */
+ public Double[] getDatatips() {
+ return datatips;
+ }
+
+ /**
+ * Return the number of datatips
+ * @return the number of datatips
+ */
+ public int getDatatipsSize() {
+ return datatips.length / 2;
+ }
+
/**
* @return Type as String
*/
@DECLARE@ __GO_Y_SHIFT__ @EQUAL@ "YShift" @END@
@DECLARE@ __GO_Z_SHIFT__ @EQUAL@ "ZShift" @END@
@DECLARE@ __GO_BAR_WIDTH__ @EQUAL@ "BarWidth" @END@
+@DECLARE@ __GO_DATATIPS__ @EQUAL@ "Datatips" @END@
+@DECLARE@ __GO_DATATIPS_SIZE__ @EQUAL@ "DatatipsSize" @END@
@DECLARE@ __GO_SURFACE_MODE__ @EQUAL@ "SurfaceMode" @END@
@DECLARE@ __GO_COLOR_MODE__ @EQUAL@ "ColorMode" @END@
src/c/getHandleProperty/get_bar_width_property.c \
src/c/getHandleProperty/get_font_color_property.c \
src/c/getHandleProperty/get_default_axes_property.c \
+src/c/getHandleProperty/get_datatips_property.c \
src/c/getHandleProperty/get_y_shift_property.c \
src/c/getHandleProperty/get_immediate_drawing_property.c \
src/c/getHandleProperty/get_current_entity_property.c \
src/c/getHandleProperty/set_text_box_mode_property.c \
src/c/getHandleProperty/set_bar_layout_property.c \
src/c/getHandleProperty/set_bar_width_property.c \
+src/c/getHandleProperty/set_datatips_property.c \
src/c/getHandleProperty/SetPropertyStatus.c \
src/c/getHandleProperty/set_font_style_property.c \
src/c/getHandleProperty/set_surface_mode_property.c \
-# Makefile.in generated by automake 1.11.6 from Makefile.am.
+# Makefile.in generated by automake 1.11.1 from Makefile.am.
# @configure_input@
# Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
-# 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Free Software
-# Foundation, Inc.
+# 2003, 2004, 2005, 2006, 2007, 2008, 2009 Free Software Foundation,
+# Inc.
# This Makefile.in is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
# with or without modifications, as long as this notice is preserved.
VPATH = @srcdir@
-am__make_dryrun = \
- { \
- am__dry=no; \
- case $$MAKEFLAGS in \
- *\\[\ \ ]*) \
- echo 'am--echo: ; @echo "AM" OK' | $(MAKE) -f - 2>/dev/null \
- | grep '^AM OK$$' >/dev/null || am__dry=yes;; \
- *) \
- for am__flg in $$MAKEFLAGS; do \
- case $$am__flg in \
- *=*|--*) ;; \
- *n*) am__dry=yes; break;; \
- esac; \
- done;; \
- esac; \
- test $$am__dry = yes; \
- }
pkgdatadir = $(datadir)/@PACKAGE@
pkgincludedir = $(includedir)/@PACKAGE@
pkglibdir = $(libdir)/@PACKAGE@
am__base_list = \
sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \
sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g'
-am__uninstall_files_from_dir = { \
- test -z "$$files" \
- || { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \
- || { echo " ( cd '$$dir' && rm -f" $$files ")"; \
- $(am__cd) "$$dir" && rm -f $$files; }; \
- }
am__installdirs = "$(DESTDIR)$(pkglibdir)" \
"$(DESTDIR)$(libscigraphics_la_etcdir)" \
"$(DESTDIR)$(libscigraphics_la_rootdir)" \
libscigraphics_algo_la-get_bar_width_property.lo \
libscigraphics_algo_la-get_font_color_property.lo \
libscigraphics_algo_la-get_default_axes_property.lo \
+ libscigraphics_algo_la-get_datatips_property.lo \
libscigraphics_algo_la-get_y_shift_property.lo \
libscigraphics_algo_la-get_immediate_drawing_property.lo \
libscigraphics_algo_la-get_current_entity_property.lo \
libscigraphics_algo_la-set_text_box_mode_property.lo \
libscigraphics_algo_la-set_bar_layout_property.lo \
libscigraphics_algo_la-set_bar_width_property.lo \
+ libscigraphics_algo_la-set_datatips_property.lo \
libscigraphics_algo_la-SetPropertyStatus.lo \
libscigraphics_algo_la-set_font_style_property.lo \
libscigraphics_algo_la-set_surface_mode_property.lo \
DIST_SOURCES = $(libscigraphics_algo_la_SOURCES) \
$(libscigraphics_disable_la_SOURCES) \
$(libscigraphics_la_SOURCES)
-am__can_run_installinfo = \
- case $$AM_UPDATE_INFO_DIR in \
- n|no|NO) false;; \
- *) (install-info --version) >/dev/null 2>&1;; \
- esac
DATA = $(libscigraphics_la_etc_DATA) $(libscigraphics_la_root_DATA) \
$(libscigraphics_la_sci_gateway_DATA) \
$(nobase_libscigraphics_la_ged_DATA)
src/c/getHandleProperty/get_bar_width_property.c \
src/c/getHandleProperty/get_font_color_property.c \
src/c/getHandleProperty/get_default_axes_property.c \
+src/c/getHandleProperty/get_datatips_property.c \
src/c/getHandleProperty/get_y_shift_property.c \
src/c/getHandleProperty/get_immediate_drawing_property.c \
src/c/getHandleProperty/get_current_entity_property.c \
src/c/getHandleProperty/set_text_box_mode_property.c \
src/c/getHandleProperty/set_bar_layout_property.c \
src/c/getHandleProperty/set_bar_width_property.c \
+src/c/getHandleProperty/set_datatips_property.c \
src/c/getHandleProperty/SetPropertyStatus.c \
src/c/getHandleProperty/set_font_style_property.c \
src/c/getHandleProperty/set_surface_mode_property.c \
echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \
cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \
esac;
-$(top_srcdir)/Makefile.incl.am:
$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
done
install-pkglibLTLIBRARIES: $(pkglib_LTLIBRARIES)
@$(NORMAL_INSTALL)
+ test -z "$(pkglibdir)" || $(MKDIR_P) "$(DESTDIR)$(pkglibdir)"
@list='$(pkglib_LTLIBRARIES)'; test -n "$(pkglibdir)" || list=; \
list2=; for p in $$list; do \
if test -f $$p; then \
else :; fi; \
done; \
test -z "$$list2" || { \
- echo " $(MKDIR_P) '$(DESTDIR)$(pkglibdir)'"; \
- $(MKDIR_P) "$(DESTDIR)$(pkglibdir)" || exit 1; \
echo " $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL) $(INSTALL_STRIP_FLAG) $$list2 '$(DESTDIR)$(pkglibdir)'"; \
$(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL) $(INSTALL_STRIP_FLAG) $$list2 "$(DESTDIR)$(pkglibdir)"; \
}
echo "rm -f \"$${dir}/so_locations\""; \
rm -f "$${dir}/so_locations"; \
done
-libscigraphics-algo.la: $(libscigraphics_algo_la_OBJECTS) $(libscigraphics_algo_la_DEPENDENCIES) $(EXTRA_libscigraphics_algo_la_DEPENDENCIES)
+libscigraphics-algo.la: $(libscigraphics_algo_la_OBJECTS) $(libscigraphics_algo_la_DEPENDENCIES)
$(LINK) $(am_libscigraphics_algo_la_rpath) $(libscigraphics_algo_la_OBJECTS) $(libscigraphics_algo_la_LIBADD) $(LIBS)
-libscigraphics-disable.la: $(libscigraphics_disable_la_OBJECTS) $(libscigraphics_disable_la_DEPENDENCIES) $(EXTRA_libscigraphics_disable_la_DEPENDENCIES)
+libscigraphics-disable.la: $(libscigraphics_disable_la_OBJECTS) $(libscigraphics_disable_la_DEPENDENCIES)
$(LINK) -rpath $(pkglibdir) $(libscigraphics_disable_la_OBJECTS) $(libscigraphics_disable_la_LIBADD) $(LIBS)
-libscigraphics.la: $(libscigraphics_la_OBJECTS) $(libscigraphics_la_DEPENDENCIES) $(EXTRA_libscigraphics_la_DEPENDENCIES)
+libscigraphics.la: $(libscigraphics_la_OBJECTS) $(libscigraphics_la_DEPENDENCIES)
$(LINK) $(am_libscigraphics_la_rpath) $(libscigraphics_la_OBJECTS) $(libscigraphics_la_LIBADD) $(LIBS)
mostlyclean-compile:
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libscigraphics_algo_la-get_data_bounds_property.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libscigraphics_algo_la-get_data_mapping_property.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libscigraphics_algo_la-get_data_property.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libscigraphics_algo_la-get_datatips_property.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libscigraphics_algo_la-get_default_axes_property.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libscigraphics_algo_la-get_default_figure_property.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libscigraphics_algo_la-get_event_handler_enable_property.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libscigraphics_algo_la-set_data_bounds_property.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libscigraphics_algo_la-set_data_mapping_property.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libscigraphics_algo_la-set_data_property.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libscigraphics_algo_la-set_datatips_property.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libscigraphics_algo_la-set_default_values_property.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libscigraphics_algo_la-set_event_handler_enable_property.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libscigraphics_algo_la-set_event_handler_property.Plo@am__quote@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libscigraphics_algo_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o libscigraphics_algo_la-get_default_axes_property.lo `test -f 'src/c/getHandleProperty/get_default_axes_property.c' || echo '$(srcdir)/'`src/c/getHandleProperty/get_default_axes_property.c
+libscigraphics_algo_la-get_datatips_property.lo: src/c/getHandleProperty/get_datatips_property.c
+@am__fastdepCC_TRUE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libscigraphics_algo_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT libscigraphics_algo_la-get_datatips_property.lo -MD -MP -MF $(DEPDIR)/libscigraphics_algo_la-get_datatips_property.Tpo -c -o libscigraphics_algo_la-get_datatips_property.lo `test -f 'src/c/getHandleProperty/get_datatips_property.c' || echo '$(srcdir)/'`src/c/getHandleProperty/get_datatips_property.c
+@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/libscigraphics_algo_la-get_datatips_property.Tpo $(DEPDIR)/libscigraphics_algo_la-get_datatips_property.Plo
+@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='src/c/getHandleProperty/get_datatips_property.c' object='libscigraphics_algo_la-get_datatips_property.lo' libtool=yes @AMDEPBACKSLASH@
+@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
+@am__fastdepCC_FALSE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libscigraphics_algo_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o libscigraphics_algo_la-get_datatips_property.lo `test -f 'src/c/getHandleProperty/get_datatips_property.c' || echo '$(srcdir)/'`src/c/getHandleProperty/get_datatips_property.c
+
libscigraphics_algo_la-get_y_shift_property.lo: src/c/getHandleProperty/get_y_shift_property.c
@am__fastdepCC_TRUE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libscigraphics_algo_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT libscigraphics_algo_la-get_y_shift_property.lo -MD -MP -MF $(DEPDIR)/libscigraphics_algo_la-get_y_shift_property.Tpo -c -o libscigraphics_algo_la-get_y_shift_property.lo `test -f 'src/c/getHandleProperty/get_y_shift_property.c' || echo '$(srcdir)/'`src/c/getHandleProperty/get_y_shift_property.c
@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/libscigraphics_algo_la-get_y_shift_property.Tpo $(DEPDIR)/libscigraphics_algo_la-get_y_shift_property.Plo
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libscigraphics_algo_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o libscigraphics_algo_la-set_bar_width_property.lo `test -f 'src/c/getHandleProperty/set_bar_width_property.c' || echo '$(srcdir)/'`src/c/getHandleProperty/set_bar_width_property.c
+libscigraphics_algo_la-set_datatips_property.lo: src/c/getHandleProperty/set_datatips_property.c
+@am__fastdepCC_TRUE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libscigraphics_algo_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT libscigraphics_algo_la-set_datatips_property.lo -MD -MP -MF $(DEPDIR)/libscigraphics_algo_la-set_datatips_property.Tpo -c -o libscigraphics_algo_la-set_datatips_property.lo `test -f 'src/c/getHandleProperty/set_datatips_property.c' || echo '$(srcdir)/'`src/c/getHandleProperty/set_datatips_property.c
+@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/libscigraphics_algo_la-set_datatips_property.Tpo $(DEPDIR)/libscigraphics_algo_la-set_datatips_property.Plo
+@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='src/c/getHandleProperty/set_datatips_property.c' object='libscigraphics_algo_la-set_datatips_property.lo' libtool=yes @AMDEPBACKSLASH@
+@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
+@am__fastdepCC_FALSE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libscigraphics_algo_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o libscigraphics_algo_la-set_datatips_property.lo `test -f 'src/c/getHandleProperty/set_datatips_property.c' || echo '$(srcdir)/'`src/c/getHandleProperty/set_datatips_property.c
+
libscigraphics_algo_la-SetPropertyStatus.lo: src/c/getHandleProperty/SetPropertyStatus.c
@am__fastdepCC_TRUE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libscigraphics_algo_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT libscigraphics_algo_la-SetPropertyStatus.lo -MD -MP -MF $(DEPDIR)/libscigraphics_algo_la-SetPropertyStatus.Tpo -c -o libscigraphics_algo_la-SetPropertyStatus.lo `test -f 'src/c/getHandleProperty/SetPropertyStatus.c' || echo '$(srcdir)/'`src/c/getHandleProperty/SetPropertyStatus.c
@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/libscigraphics_algo_la-SetPropertyStatus.Tpo $(DEPDIR)/libscigraphics_algo_la-SetPropertyStatus.Plo
-rm -rf .libs _libs
install-libscigraphics_la_etcDATA: $(libscigraphics_la_etc_DATA)
@$(NORMAL_INSTALL)
+ test -z "$(libscigraphics_la_etcdir)" || $(MKDIR_P) "$(DESTDIR)$(libscigraphics_la_etcdir)"
@list='$(libscigraphics_la_etc_DATA)'; test -n "$(libscigraphics_la_etcdir)" || list=; \
- if test -n "$$list"; then \
- echo " $(MKDIR_P) '$(DESTDIR)$(libscigraphics_la_etcdir)'"; \
- $(MKDIR_P) "$(DESTDIR)$(libscigraphics_la_etcdir)" || exit 1; \
- fi; \
for p in $$list; do \
if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \
echo "$$d$$p"; \
@$(NORMAL_UNINSTALL)
@list='$(libscigraphics_la_etc_DATA)'; test -n "$(libscigraphics_la_etcdir)" || list=; \
files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \
- dir='$(DESTDIR)$(libscigraphics_la_etcdir)'; $(am__uninstall_files_from_dir)
+ test -n "$$files" || exit 0; \
+ echo " ( cd '$(DESTDIR)$(libscigraphics_la_etcdir)' && rm -f" $$files ")"; \
+ cd "$(DESTDIR)$(libscigraphics_la_etcdir)" && rm -f $$files
install-libscigraphics_la_rootDATA: $(libscigraphics_la_root_DATA)
@$(NORMAL_INSTALL)
+ test -z "$(libscigraphics_la_rootdir)" || $(MKDIR_P) "$(DESTDIR)$(libscigraphics_la_rootdir)"
@list='$(libscigraphics_la_root_DATA)'; test -n "$(libscigraphics_la_rootdir)" || list=; \
- if test -n "$$list"; then \
- echo " $(MKDIR_P) '$(DESTDIR)$(libscigraphics_la_rootdir)'"; \
- $(MKDIR_P) "$(DESTDIR)$(libscigraphics_la_rootdir)" || exit 1; \
- fi; \
for p in $$list; do \
if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \
echo "$$d$$p"; \
@$(NORMAL_UNINSTALL)
@list='$(libscigraphics_la_root_DATA)'; test -n "$(libscigraphics_la_rootdir)" || list=; \
files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \
- dir='$(DESTDIR)$(libscigraphics_la_rootdir)'; $(am__uninstall_files_from_dir)
+ test -n "$$files" || exit 0; \
+ echo " ( cd '$(DESTDIR)$(libscigraphics_la_rootdir)' && rm -f" $$files ")"; \
+ cd "$(DESTDIR)$(libscigraphics_la_rootdir)" && rm -f $$files
install-libscigraphics_la_sci_gatewayDATA: $(libscigraphics_la_sci_gateway_DATA)
@$(NORMAL_INSTALL)
+ test -z "$(libscigraphics_la_sci_gatewaydir)" || $(MKDIR_P) "$(DESTDIR)$(libscigraphics_la_sci_gatewaydir)"
@list='$(libscigraphics_la_sci_gateway_DATA)'; test -n "$(libscigraphics_la_sci_gatewaydir)" || list=; \
- if test -n "$$list"; then \
- echo " $(MKDIR_P) '$(DESTDIR)$(libscigraphics_la_sci_gatewaydir)'"; \
- $(MKDIR_P) "$(DESTDIR)$(libscigraphics_la_sci_gatewaydir)" || exit 1; \
- fi; \
for p in $$list; do \
if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \
echo "$$d$$p"; \
@$(NORMAL_UNINSTALL)
@list='$(libscigraphics_la_sci_gateway_DATA)'; test -n "$(libscigraphics_la_sci_gatewaydir)" || list=; \
files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \
- dir='$(DESTDIR)$(libscigraphics_la_sci_gatewaydir)'; $(am__uninstall_files_from_dir)
+ test -n "$$files" || exit 0; \
+ echo " ( cd '$(DESTDIR)$(libscigraphics_la_sci_gatewaydir)' && rm -f" $$files ")"; \
+ cd "$(DESTDIR)$(libscigraphics_la_sci_gatewaydir)" && rm -f $$files
install-nobase_libscigraphics_la_gedDATA: $(nobase_libscigraphics_la_ged_DATA)
@$(NORMAL_INSTALL)
+ test -z "$(libscigraphics_la_geddir)" || $(MKDIR_P) "$(DESTDIR)$(libscigraphics_la_geddir)"
@list='$(nobase_libscigraphics_la_ged_DATA)'; test -n "$(libscigraphics_la_geddir)" || list=; \
- if test -n "$$list"; then \
- echo " $(MKDIR_P) '$(DESTDIR)$(libscigraphics_la_geddir)'"; \
- $(MKDIR_P) "$(DESTDIR)$(libscigraphics_la_geddir)" || exit 1; \
- fi; \
$(am__nobase_list) | while read dir files; do \
xfiles=; for file in $$files; do \
if test -f "$$file"; then xfiles="$$xfiles $$file"; \
else xfiles="$$xfiles $(srcdir)/$$file"; fi; done; \
test -z "$$xfiles" || { \
test "x$$dir" = x. || { \
- echo " $(MKDIR_P) '$(DESTDIR)$(libscigraphics_la_geddir)/$$dir'"; \
+ echo "$(MKDIR_P) '$(DESTDIR)$(libscigraphics_la_geddir)/$$dir'"; \
$(MKDIR_P) "$(DESTDIR)$(libscigraphics_la_geddir)/$$dir"; }; \
echo " $(INSTALL_DATA) $$xfiles '$(DESTDIR)$(libscigraphics_la_geddir)/$$dir'"; \
$(INSTALL_DATA) $$xfiles "$(DESTDIR)$(libscigraphics_la_geddir)/$$dir" || exit $$?; }; \
@$(NORMAL_UNINSTALL)
@list='$(nobase_libscigraphics_la_ged_DATA)'; test -n "$(libscigraphics_la_geddir)" || list=; \
$(am__nobase_strip_setup); files=`$(am__nobase_strip)`; \
- dir='$(DESTDIR)$(libscigraphics_la_geddir)'; $(am__uninstall_files_from_dir)
+ test -n "$$files" || exit 0; \
+ echo " ( cd '$(DESTDIR)$(libscigraphics_la_geddir)' && rm -f" $$files ")"; \
+ cd "$(DESTDIR)$(libscigraphics_la_geddir)" && rm -f $$files
ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES)
list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \
installcheck: installcheck-am
install-strip:
- if test -z '$(STRIP)'; then \
- $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
- install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
- install; \
- else \
- $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
- install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
- "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \
- fi
+ $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
+ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
+ `test -z '$(STRIP)' || \
+ echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install
mostlyclean-generic:
clean-generic:
<ClCompile Include="src\c\getHandleProperty\get_background_property.c" />
<ClCompile Include="src\c\getHandleProperty\get_bar_layout_property.c" />
<ClCompile Include="src\c\getHandleProperty\get_bar_width_property.c" />
+ <ClCompile Include="src\c\getHandleProperty\get_datatips_property.c" />
<ClCompile Include="src\c\getHandleProperty\get_box_property.c" />
<ClCompile Include="src\c\getHandleProperty\get_callback_property.c" />
<ClCompile Include="src\c\getHandleProperty\get_callback_type_property.c" />
<ClCompile Include="src\c\getHandleProperty\set_background_property.c" />
<ClCompile Include="src\c\getHandleProperty\set_bar_layout_property.c" />
<ClCompile Include="src\c\getHandleProperty\set_bar_width_property.c" />
+ <ClCompile Include="src\c\getHandleProperty\set_datatips_property.c" />
<ClCompile Include="src\c\getHandleProperty\set_box_property.c" />
<ClCompile Include="src\c\getHandleProperty\set_callback_property.c" />
<ClCompile Include="src\c\getHandleProperty\set_callback_type_property.c" />
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
<ImportGroup Label="ExtensionTargets">
</ImportGroup>
-</Project>
\ No newline at end of file
+</Project>
<ClCompile Include="src\c\getHandleProperty\get_bar_width_property.c">
<Filter>Source Files</Filter>
</ClCompile>
+ <ClCompile Include="src\c\getHandleProperty\get_datatips_property.c">
+ <Filter>Source Files</Filter>
+ </ClCompile>
<ClCompile Include="src\c\getHandleProperty\get_box_property.c">
<Filter>Source Files</Filter>
</ClCompile>
<ClCompile Include="src\c\getHandleProperty\set_bar_width_property.c">
<Filter>Source Files</Filter>
</ClCompile>
+ <ClCompile Include="src\c\getHandleProperty\set_datatips_property.c">
+ <Filter>Source Files</Filter>
+ </ClCompile>
<ClCompile Include="src\c\getHandleProperty\set_box_property.c">
<Filter>Source Files</Filter>
</ClCompile>
<Filter>Resource Files</Filter>
</ResourceCompile>
</ItemGroup>
-</Project>
\ No newline at end of file
+</Project>
bar_width = mget( 1, 'dl', fd ) ; // bar_width
end
+ datatips=matrix(mget(mget(1,'il',fd),"dl",fd),-1,3) // datatips
+
clip_state = ascii(mget(mget(1,characterFormat,fd),characterFormat,fd)) // clip_state
if clip_state=='on' then
set(h,"bar_width",bar_width);
end
+ set(h,"datatips",datatips),
+
if clip_state =='' then clip_state='clipgrf',end
if clip_state=='on' then set(h,"clip_box",clip_box),end
set(h,"clip_state",clip_state);
"y_shift = "+bys
"z_shift = "+bzs
"bar_width = "+sci2exp(h.bar_width)
+ "datatips = matrix "+strcat(string(size(h.datatips)),'x')
"clip_state = "+sci2exp(h.clip_state)
"clip_box = "+sci2exp(h.clip_box)
"user_data = "+fmtuser_data(u)
mput(size(h.z_shift,'*'),'sl',fd); mput(h.z_shift,'dl',fd); // z_shift
mput( h.bar_width, 'dl', fd ) ; // bar_width
+
+ mput(size(h.datatips,'*'),'il',fd); // datatips
+ mput(h.datatips,'dl',fd);
+
mput(length(h.clip_state),characterFormat,fd); // clip_state
mput(ascii(h.clip_state),characterFormat,fd);
if h.clip_state=='on' then
* don't forget to modify it each time the propertyTable
* is modified.
*/
-#define NB_PROPERTIES 162
+#define NB_PROPERTIES 163
/**
* list of all property names and associated functions in scilab
{"mark_background", get_mark_background_property},
{"bar_layout", get_bar_layout_property},
{"bar_width", get_bar_width_property},
+ {"datatips", get_datatips_property},
{"x_shift", get_x_shift_property},
{"y_shift", get_y_shift_property},
{"z_shift", get_z_shift_property},
* don't forget to modify it each time the propertyTable
* is modified.
*/
-#define NB_PROPERTIES 157
+#define NB_PROPERTIES 158
/**
* list of all property names and associated functions in scilab
{"mark_background", set_mark_background_property},
{"bar_layout", set_bar_layout_property},
{"bar_width", set_bar_width_property},
+ {"datatips", set_datatips_property},
{"x_shift", set_x_shift_property},
{"y_shift", set_y_shift_property},
{"z_shift", set_z_shift_property},
int get_mark_background_property(void* _pvCtx, char* pobjUID);
int get_bar_layout_property(void* _pvCtx, char* pobjUID);
int get_bar_width_property(void* _pvCtx, char* pobjUID);
+int get_datatips_property(void* _pvCtx, char* pobjUID);
int get_x_shift_property(void* _pvCtx, char* pobjUID);
int get_y_shift_property(void* _pvCtx, char* pobjUID);
int get_z_shift_property(void* _pvCtx, char* pobjUID);
--- /dev/null
+/*
+ * Scilab ( http://www.scilab.org/ ) - This file is part of Scilab
+ * Copyright (C) 2012 - Gustavo Barbosa Libotte
+ *
+ * This file must be used under the terms of the CeCILL.
+ * This source file is licensed as described in the file COPYING, which
+ * you should have received as part of this distribution. The terms
+ * are also available at
+ * http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+ *
+ */
+
+/*------------------------------------------------------------------------*/
+/* file: get_datatips_property.c */
+/* desc: function to retrieve in Scilab the datatips field of a */
+/* handle */
+/*------------------------------------------------------------------------*/
+
+#include "getHandleProperty.h"
+#include "returnProperty.h"
+#include "Scierror.h"
+#include "localization.h"
+
+#include "getGraphicObjectProperty.h"
+#include "graphicObjectProperties.h"
+
+/*--------------------------------------------------------------------------*/
+int get_datatips_property(void* _pvCtx, char* pobjUID)
+{
+ double *pdblDatatips = NULL;
+
+ int iDatatipsSize = 0;
+ int * piDatatipsSize = &iDatatipsSize;
+
+ getGraphicObjectProperty(pobjUID, __GO_DATATIPS_SIZE__, jni_int, (void **)&piDatatipsSize);
+ getGraphicObjectProperty(pobjUID, __GO_DATATIPS__, jni_double_vector, (void **)&pdblDatatips);
+ if ( pdblDatatips == NULL )
+ {
+ Scierror(999, _("'%s' does not exist for this handle.\n"), "datatips");
+ return -1;
+ }
+
+ return sciReturnMatrix(_pvCtx, pdblDatatips, iDatatipsSize, 2);
+}
+/*--------------------------------------------------------------------------*/
int set_mark_foreground_property(void* _pvCtx, char* pobj, size_t stackPointer, int valueType, int nbRow, int nbCol);
int set_mark_background_property(void* _pvCtx, char* pobj, size_t stackPointer, int valueType, int nbRow, int nbCol);
int set_bar_width_property(void* _pvCtx, char* pobj, size_t stackPointer, int valueType, int nbRow, int nbCol);
+int set_datatips_property(void* _pvCtx, char* pobjUID, size_t stackPointer, int valueType, int nbRow, int nbCol );
int set_bar_layout_property(void* _pvCtx, char* pobj, size_t stackPointer, int valueType, int nbRow, int nbCol);
int set_x_shift_property(void* _pvCtx, char* pobj, size_t stackPointer, int valueType, int nbRow, int nbCol);
int set_y_shift_property(void* _pvCtx, char* pobj, size_t stackPointer, int valueType, int nbRow, int nbCol);
--- /dev/null
+/*
+ * Scilab ( http://www.scilab.org/ ) - This file is part of Scilab
+ * Copyright (C) 2012 - Gustavo Barbosa Libotte
+ *
+ * This file must be used under the terms of the CeCILL.
+ * This source file is licensed as described in the file COPYING, which
+ * you should have received as part of this distribution. The terms
+ * are also available at
+ * http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+ *
+ */
+
+/*------------------------------------------------------------------------*/
+/* file: set_datatips_property.c */
+/* desc: function to modify in Scilab the datatips field of */
+/* a handle */
+/*------------------------------------------------------------------------*/
+
+#include "setHandleProperty.h"
+#include "SetProperty.h"
+#include "getPropertyAssignedValue.h"
+#include "Scierror.h"
+#include "localization.h"
+#include "SetPropertyStatus.h"
+#include "MALLOC.h"
+
+#include "setGraphicObjectProperty.h"
+#include "graphicObjectProperties.h"
+
+#include "CallDatatipCreateField.h"
+
+/*------------------------------------------------------------------------*/
+int set_datatips_property(void* _pvCtx, char* pobjUID, size_t stackPointer, int valueType, int nbRow, int nbCol)
+{
+ BOOL status = FALSE;
+ double* currentDatatipsCoords;
+ double* newDatatipsCoords;
+ int i;
+
+ if ( !( valueType == sci_matrix ) )
+ {
+ Scierror(999, _("Wrong type for '%s' property: Real matrix expected.\n"), "datatips");
+ return SET_PROPERTY_ERROR ;
+ }
+
+ if ( !( nbRow*nbCol % 2 == 0 ) )
+ {
+ Scierror(999, _("Wrong number of input arguments for '%s' property: X and Y expected.\n"), "datatips");
+ return SET_PROPERTY_ERROR ;
+ }
+
+ currentDatatipsCoords = getDoubleMatrixFromStack(stackPointer);
+
+ newDatatipsCoords = CallDatatipCreateField((char*)pobjUID, currentDatatipsCoords, nbRow * nbCol);
+
+ status = setGraphicObjectProperty(pobjUID, __GO_DATATIPS__, newDatatipsCoords, jni_double_vector, nbRow * nbCol);
+
+ FREE(newDatatipsCoords);
+
+ if (status == TRUE)
+ {
+ return SET_PROPERTY_SUCCEED;
+ }
+ else
+ {
+ Scierror(999, _("'%s' does not exist for this handle.\n"), "datatips");
+ return SET_PROPERTY_ERROR;
+ }
+}
+/*------------------------------------------------------------------------*/
src/jni/EditorManager.cpp \
src/jni/StartGED.cpp \
src/jni/DatatipFunctions.cpp \
-src/jni/StartPlotBrowser.cpp
+src/jni/StartPlotBrowser.cpp \
+src/cpp/CallDatatipCreateField.cpp
GIWS_WRAPPERS = \
src/jni/CallScilabBridge.giws.xml \
-# Makefile.in generated by automake 1.11.6 from Makefile.am.
+# Makefile.in generated by automake 1.11.1 from Makefile.am.
# @configure_input@
# Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
-# 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Free Software
-# Foundation, Inc.
+# 2003, 2004, 2005, 2006, 2007, 2008, 2009 Free Software Foundation,
+# Inc.
# This Makefile.in is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
# with or without modifications, as long as this notice is preserved.
VPATH = @srcdir@
-am__make_dryrun = \
- { \
- am__dry=no; \
- case $$MAKEFLAGS in \
- *\\[\ \ ]*) \
- echo 'am--echo: ; @echo "AM" OK' | $(MAKE) -f - 2>/dev/null \
- | grep '^AM OK$$' >/dev/null || am__dry=yes;; \
- *) \
- for am__flg in $$MAKEFLAGS; do \
- case $$am__flg in \
- *=*|--*) ;; \
- *n*) am__dry=yes; break;; \
- esac; \
- done;; \
- esac; \
- test $$am__dry = yes; \
- }
pkgdatadir = $(datadir)/@PACKAGE@
pkgincludedir = $(includedir)/@PACKAGE@
pkglibdir = $(libdir)/@PACKAGE@
am__base_list = \
sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \
sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g'
-am__uninstall_files_from_dir = { \
- test -z "$$files" \
- || { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \
- || { echo " ( cd '$$dir' && rm -f" $$files ")"; \
- $(am__cd) "$$dir" && rm -f $$files; }; \
- }
am__installdirs = "$(DESTDIR)$(pkglibdir)" \
"$(DESTDIR)$(libscigui_la_etcdir)" \
"$(DESTDIR)$(libscigui_la_rootdir)" \
libscigui_algo_la-EditorManager.lo \
libscigui_algo_la-StartGED.lo \
libscigui_algo_la-DatatipFunctions.lo \
- libscigui_algo_la-StartPlotBrowser.lo
+ libscigui_algo_la-StartPlotBrowser.lo \
+ libscigui_algo_la-CallDatatipCreateField.lo
am_libscigui_algo_la_OBJECTS = $(am__objects_1) $(am__objects_2)
libscigui_algo_la_OBJECTS = $(am_libscigui_algo_la_OBJECTS)
@GUI_TRUE@am_libscigui_algo_la_rpath =
$(libscigui_la_SOURCES)
DIST_SOURCES = $(libscigui_algo_la_SOURCES) \
$(libscigui_disable_la_SOURCES) $(libscigui_la_SOURCES)
-am__can_run_installinfo = \
- case $$AM_UPDATE_INFO_DIR in \
- n|no|NO) false;; \
- *) (install-info --version) >/dev/null 2>&1;; \
- esac
DATA = $(libscigui_la_etc_DATA) $(libscigui_la_root_DATA) \
$(libscigui_la_sci_gateway_DATA) \
$(nobase_libscigui_la_icons_DATA)
src/jni/EditorManager.cpp \
src/jni/StartGED.cpp \
src/jni/DatatipFunctions.cpp \
-src/jni/StartPlotBrowser.cpp
+src/jni/StartPlotBrowser.cpp \
+src/cpp/CallDatatipCreateField.cpp
GIWS_WRAPPERS = \
src/jni/CallScilabBridge.giws.xml \
echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \
cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \
esac;
-$(top_srcdir)/Makefile.incl.am:
$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
done
install-pkglibLTLIBRARIES: $(pkglib_LTLIBRARIES)
@$(NORMAL_INSTALL)
+ test -z "$(pkglibdir)" || $(MKDIR_P) "$(DESTDIR)$(pkglibdir)"
@list='$(pkglib_LTLIBRARIES)'; test -n "$(pkglibdir)" || list=; \
list2=; for p in $$list; do \
if test -f $$p; then \
else :; fi; \
done; \
test -z "$$list2" || { \
- echo " $(MKDIR_P) '$(DESTDIR)$(pkglibdir)'"; \
- $(MKDIR_P) "$(DESTDIR)$(pkglibdir)" || exit 1; \
echo " $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL) $(INSTALL_STRIP_FLAG) $$list2 '$(DESTDIR)$(pkglibdir)'"; \
$(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL) $(INSTALL_STRIP_FLAG) $$list2 "$(DESTDIR)$(pkglibdir)"; \
}
echo "rm -f \"$${dir}/so_locations\""; \
rm -f "$${dir}/so_locations"; \
done
-libscigui-algo.la: $(libscigui_algo_la_OBJECTS) $(libscigui_algo_la_DEPENDENCIES) $(EXTRA_libscigui_algo_la_DEPENDENCIES)
+libscigui-algo.la: $(libscigui_algo_la_OBJECTS) $(libscigui_algo_la_DEPENDENCIES)
$(CXXLINK) $(am_libscigui_algo_la_rpath) $(libscigui_algo_la_OBJECTS) $(libscigui_algo_la_LIBADD) $(LIBS)
-libscigui-disable.la: $(libscigui_disable_la_OBJECTS) $(libscigui_disable_la_DEPENDENCIES) $(EXTRA_libscigui_disable_la_DEPENDENCIES)
+libscigui-disable.la: $(libscigui_disable_la_OBJECTS) $(libscigui_disable_la_DEPENDENCIES)
$(LINK) -rpath $(pkglibdir) $(libscigui_disable_la_OBJECTS) $(libscigui_disable_la_LIBADD) $(LIBS)
-libscigui.la: $(libscigui_la_OBJECTS) $(libscigui_la_DEPENDENCIES) $(EXTRA_libscigui_la_DEPENDENCIES)
+libscigui.la: $(libscigui_la_OBJECTS) $(libscigui_la_DEPENDENCIES)
$(CXXLINK) $(am_libscigui_la_rpath) $(libscigui_la_OBJECTS) $(libscigui_la_LIBADD) $(LIBS)
mostlyclean-compile:
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libscigui_algo_la-CallClipboard.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libscigui_algo_la-CallColorChooser.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libscigui_algo_la-CallDatatipCreateField.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libscigui_algo_la-CallFontChooser.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libscigui_algo_la-CallHelpBrowser.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libscigui_algo_la-CallJuigetfile.Plo@am__quote@
@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCXX_FALSE@ $(LIBTOOL) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libscigui_algo_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o libscigui_algo_la-StartPlotBrowser.lo `test -f 'src/jni/StartPlotBrowser.cpp' || echo '$(srcdir)/'`src/jni/StartPlotBrowser.cpp
+libscigui_algo_la-CallDatatipCreateField.lo: src/cpp/CallDatatipCreateField.cpp
+@am__fastdepCXX_TRUE@ $(LIBTOOL) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libscigui_algo_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT libscigui_algo_la-CallDatatipCreateField.lo -MD -MP -MF $(DEPDIR)/libscigui_algo_la-CallDatatipCreateField.Tpo -c -o libscigui_algo_la-CallDatatipCreateField.lo `test -f 'src/cpp/CallDatatipCreateField.cpp' || echo '$(srcdir)/'`src/cpp/CallDatatipCreateField.cpp
+@am__fastdepCXX_TRUE@ $(am__mv) $(DEPDIR)/libscigui_algo_la-CallDatatipCreateField.Tpo $(DEPDIR)/libscigui_algo_la-CallDatatipCreateField.Plo
+@AMDEP_TRUE@@am__fastdepCXX_FALSE@ source='src/cpp/CallDatatipCreateField.cpp' object='libscigui_algo_la-CallDatatipCreateField.lo' libtool=yes @AMDEPBACKSLASH@
+@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@
+@am__fastdepCXX_FALSE@ $(LIBTOOL) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libscigui_algo_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o libscigui_algo_la-CallDatatipCreateField.lo `test -f 'src/cpp/CallDatatipCreateField.cpp' || echo '$(srcdir)/'`src/cpp/CallDatatipCreateField.cpp
+
libscigui_la-sci_printsetupbox.lo: sci_gateway/cpp/sci_printsetupbox.cpp
@am__fastdepCXX_TRUE@ $(LIBTOOL) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libscigui_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT libscigui_la-sci_printsetupbox.lo -MD -MP -MF $(DEPDIR)/libscigui_la-sci_printsetupbox.Tpo -c -o libscigui_la-sci_printsetupbox.lo `test -f 'sci_gateway/cpp/sci_printsetupbox.cpp' || echo '$(srcdir)/'`sci_gateway/cpp/sci_printsetupbox.cpp
@am__fastdepCXX_TRUE@ $(am__mv) $(DEPDIR)/libscigui_la-sci_printsetupbox.Tpo $(DEPDIR)/libscigui_la-sci_printsetupbox.Plo
-rm -rf .libs _libs
install-libscigui_la_etcDATA: $(libscigui_la_etc_DATA)
@$(NORMAL_INSTALL)
+ test -z "$(libscigui_la_etcdir)" || $(MKDIR_P) "$(DESTDIR)$(libscigui_la_etcdir)"
@list='$(libscigui_la_etc_DATA)'; test -n "$(libscigui_la_etcdir)" || list=; \
- if test -n "$$list"; then \
- echo " $(MKDIR_P) '$(DESTDIR)$(libscigui_la_etcdir)'"; \
- $(MKDIR_P) "$(DESTDIR)$(libscigui_la_etcdir)" || exit 1; \
- fi; \
for p in $$list; do \
if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \
echo "$$d$$p"; \
@$(NORMAL_UNINSTALL)
@list='$(libscigui_la_etc_DATA)'; test -n "$(libscigui_la_etcdir)" || list=; \
files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \
- dir='$(DESTDIR)$(libscigui_la_etcdir)'; $(am__uninstall_files_from_dir)
+ test -n "$$files" || exit 0; \
+ echo " ( cd '$(DESTDIR)$(libscigui_la_etcdir)' && rm -f" $$files ")"; \
+ cd "$(DESTDIR)$(libscigui_la_etcdir)" && rm -f $$files
install-libscigui_la_rootDATA: $(libscigui_la_root_DATA)
@$(NORMAL_INSTALL)
+ test -z "$(libscigui_la_rootdir)" || $(MKDIR_P) "$(DESTDIR)$(libscigui_la_rootdir)"
@list='$(libscigui_la_root_DATA)'; test -n "$(libscigui_la_rootdir)" || list=; \
- if test -n "$$list"; then \
- echo " $(MKDIR_P) '$(DESTDIR)$(libscigui_la_rootdir)'"; \
- $(MKDIR_P) "$(DESTDIR)$(libscigui_la_rootdir)" || exit 1; \
- fi; \
for p in $$list; do \
if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \
echo "$$d$$p"; \
@$(NORMAL_UNINSTALL)
@list='$(libscigui_la_root_DATA)'; test -n "$(libscigui_la_rootdir)" || list=; \
files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \
- dir='$(DESTDIR)$(libscigui_la_rootdir)'; $(am__uninstall_files_from_dir)
+ test -n "$$files" || exit 0; \
+ echo " ( cd '$(DESTDIR)$(libscigui_la_rootdir)' && rm -f" $$files ")"; \
+ cd "$(DESTDIR)$(libscigui_la_rootdir)" && rm -f $$files
install-libscigui_la_sci_gatewayDATA: $(libscigui_la_sci_gateway_DATA)
@$(NORMAL_INSTALL)
+ test -z "$(libscigui_la_sci_gatewaydir)" || $(MKDIR_P) "$(DESTDIR)$(libscigui_la_sci_gatewaydir)"
@list='$(libscigui_la_sci_gateway_DATA)'; test -n "$(libscigui_la_sci_gatewaydir)" || list=; \
- if test -n "$$list"; then \
- echo " $(MKDIR_P) '$(DESTDIR)$(libscigui_la_sci_gatewaydir)'"; \
- $(MKDIR_P) "$(DESTDIR)$(libscigui_la_sci_gatewaydir)" || exit 1; \
- fi; \
for p in $$list; do \
if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \
echo "$$d$$p"; \
@$(NORMAL_UNINSTALL)
@list='$(libscigui_la_sci_gateway_DATA)'; test -n "$(libscigui_la_sci_gatewaydir)" || list=; \
files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \
- dir='$(DESTDIR)$(libscigui_la_sci_gatewaydir)'; $(am__uninstall_files_from_dir)
+ test -n "$$files" || exit 0; \
+ echo " ( cd '$(DESTDIR)$(libscigui_la_sci_gatewaydir)' && rm -f" $$files ")"; \
+ cd "$(DESTDIR)$(libscigui_la_sci_gatewaydir)" && rm -f $$files
install-nobase_libscigui_la_iconsDATA: $(nobase_libscigui_la_icons_DATA)
@$(NORMAL_INSTALL)
+ test -z "$(libscigui_la_iconsdir)" || $(MKDIR_P) "$(DESTDIR)$(libscigui_la_iconsdir)"
@list='$(nobase_libscigui_la_icons_DATA)'; test -n "$(libscigui_la_iconsdir)" || list=; \
- if test -n "$$list"; then \
- echo " $(MKDIR_P) '$(DESTDIR)$(libscigui_la_iconsdir)'"; \
- $(MKDIR_P) "$(DESTDIR)$(libscigui_la_iconsdir)" || exit 1; \
- fi; \
$(am__nobase_list) | while read dir files; do \
xfiles=; for file in $$files; do \
if test -f "$$file"; then xfiles="$$xfiles $$file"; \
else xfiles="$$xfiles $(srcdir)/$$file"; fi; done; \
test -z "$$xfiles" || { \
test "x$$dir" = x. || { \
- echo " $(MKDIR_P) '$(DESTDIR)$(libscigui_la_iconsdir)/$$dir'"; \
+ echo "$(MKDIR_P) '$(DESTDIR)$(libscigui_la_iconsdir)/$$dir'"; \
$(MKDIR_P) "$(DESTDIR)$(libscigui_la_iconsdir)/$$dir"; }; \
echo " $(INSTALL_DATA) $$xfiles '$(DESTDIR)$(libscigui_la_iconsdir)/$$dir'"; \
$(INSTALL_DATA) $$xfiles "$(DESTDIR)$(libscigui_la_iconsdir)/$$dir" || exit $$?; }; \
@$(NORMAL_UNINSTALL)
@list='$(nobase_libscigui_la_icons_DATA)'; test -n "$(libscigui_la_iconsdir)" || list=; \
$(am__nobase_strip_setup); files=`$(am__nobase_strip)`; \
- dir='$(DESTDIR)$(libscigui_la_iconsdir)'; $(am__uninstall_files_from_dir)
+ test -n "$$files" || exit 0; \
+ echo " ( cd '$(DESTDIR)$(libscigui_la_iconsdir)' && rm -f" $$files ")"; \
+ cd "$(DESTDIR)$(libscigui_la_iconsdir)" && rm -f $$files
ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES)
list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \
installcheck: installcheck-am
install-strip:
- if test -z '$(STRIP)'; then \
- $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
- install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
- install; \
- else \
- $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
- install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
- "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \
- fi
+ $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
+ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
+ `test -z '$(STRIP)' || \
+ echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install
mostlyclean-generic:
clean-generic:
--- /dev/null
+#ifndef __CALLDATATIPCREATEFIELD_H__
+#define __CALLDATATIPCREATEFIELD_H__
+
+/*
+ * Scilab ( http://www.scilab.org/ ) - This file is part of Scilab
+ * Copyright (C) 2012 - Gustavo Barbosa Libotte
+ *
+ * This file must be used under the terms of the CeCILL.
+ * This source file is licensed as described in the file COPYING, which
+ * you should have received as part of this distribution. The terms
+ * are also available at
+ * http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+ *
+ */
+
+#include "dynlib_gui.h"
+
+GUI_IMPEXP double* CallDatatipCreateField(char const* polylineUid, double const* coordDoubleXY, int coordDoubleXYSize);
+#endif
return FALSE;
}
+ nbRow = 1;
+ nbCol = 1;
CreateVar(Rhs + 1, GRAPHICAL_HANDLE_DATATYPE, &nbRow, &nbCol, &out_index);
hstk(out_index)[0] = getHandle(datatip_handler);
LhsVar(1) = Rhs + 1;
int* piAddr = NULL;
double* pdblReal = NULL;
int indexPos = 0;
+ int *status = NULL;
if (Rhs == 1)
{
return FALSE;
}
+ if ((status = (int *)MALLOC(sizeof(int))) == NULL)
+ {
+ Scierror(999, _("%s: No more memory.\n"), fname, 0);
+ return FALSE;
+ }
+
+ nbRow = 1;
+ nbCol = 1;
+ CreateVarFromPtr(Rhs + 1, MATRIX_OF_BOOLEAN_DATATYPE, &nbRow, &nbCol, &status);
+
+ FREE(status);
+
+ LhsVar(1) = Rhs + 1;
+ PutLhsVar();
+
+ return TRUE;
+
}
<ClCompile Include="..\cpp\CallFontChooser.cpp" />
<ClCompile Include="..\cpp\CallHelpBrowser.cpp" />
<ClCompile Include="..\cpp\CallJuigetfile.cpp" />
+ <ClCompile Include="..\cpp\CallDatatipCreateField.cpp" />
<ClCompile Include="..\cpp\CallJxclick.cpp" />
<ClCompile Include="..\cpp\CallJxgetmouse.cpp" />
<ClCompile Include="..\cpp\CallMessageBox.cpp" />
<ClInclude Include="..\..\includes\CallJuigetfile.h" />
<ClInclude Include="..\..\includes\CallJuigetfile.hxx" />
<ClInclude Include="..\..\includes\CallJxclick.h" />
+ <ClInclude Include="..\..\includes\CallDatatipCreateField.h" />
<ClInclude Include="..\..\includes\CallJxgetmouse.h" />
<ClInclude Include="..\..\includes\CallMessageBox.h" />
<ClInclude Include="..\..\includes\ContextMenu.h" />
<ClInclude Include="..\cpp\CallHelpBrowser.hxx" />
<ClInclude Include="..\cpp\CallJxclick.hxx" />
<ClInclude Include="..\cpp\CallJxgetmouse.hxx" />
+ <ClInclude Include="..\cpp\CallDatatipCreateField.hxx" />
<ClInclude Include="..\cpp\CallMainWindow.hxx" />
<ClInclude Include="..\cpp\CallMessageBox.hxx" />
<ClInclude Include="..\cpp\ContextMenu.hxx" />
<ClCompile Include="..\cpp\CallJxclick.cpp">
<Filter>Source Files</Filter>
</ClCompile>
+ <ClCompile Include="..\cpp\CallDatatipCreateField.cpp">
+ <Filter>Source Files</Filter>
+ </ClCompile>
<ClCompile Include="..\cpp\CallJxgetmouse.cpp">
<Filter>Source Files</Filter>
</ClCompile>
<ClInclude Include="..\cpp\CallJxgetmouse.hxx">
<Filter>Header Files</Filter>
</ClInclude>
+ <ClInclude Include="..\cpp\CallDatatipCreateField.hxx">
+ <Filter>Header Files</Filter>
+ </ClInclude>
<ClInclude Include="..\cpp\CallMainWindow.hxx">
<Filter>Header Files</Filter>
</ClInclude>
<ClInclude Include="..\..\includes\CallJxclick.h">
<Filter>Header Files</Filter>
</ClInclude>
+ <ClInclude Include="..\..\includes\CallDatatipCreateField.h">
+ <Filter>Header Files</Filter>
+ </ClInclude>
<ClInclude Include="..\..\includes\CallJxgetmouse.h">
<Filter>Header Files</Filter>
</ClInclude>
--- /dev/null
+/*
+ * Scilab ( http://www.scilab.org/ ) - This file is part of Scilab
+ * Copyright (C) 2012 - Gustavo Barbosa Libotte
+ *
+ * This file must be used under the terms of the CeCILL.
+ * This source file is licensed as described in the file COPYING, which
+ * you should have received as part of this distribution. The terms
+ * are also available at
+ * http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+ *
+ */
+
+#include "CallDatatipCreateField.hxx"
+
+using namespace org_scilab_modules_gui_datatip;
+
+double* CallDatatipCreateField(char const* polylineUid, double const* coordDoubleXY, int coordDoubleXYSize)
+{
+ DatatipCreate::createDatatipField(getScilabJavaVM(), polylineUid, coordDoubleXY, coordDoubleXYSize);
+}
--- /dev/null
+#ifndef __CALLDATATIPCREATEFIELD_HXX__
+#define __CALLDATATIPCREATEFIELD_HXX__
+
+/*
+ * Scilab ( http://www.scilab.org/ ) - This file is part of Scilab
+ * Copyright (C) 2012 - Gustavo Barbosa Libotte
+ *
+ * This file must be used under the terms of the CeCILL.
+ * This source file is licensed as described in the file COPYING, which
+ * you should have received as part of this distribution. The terms
+ * are also available at
+ * http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+ *
+ */
+
+#include "DatatipFunctions.hxx"
+extern "C" {
+#include "getScilabJavaVM.h"
+#include "CallDatatipCreateField.h"
+}
+
+#endif
public static Double[] datatipPosition = new Double[3];
private static double[] pixelMouseCoordDouble = new double[2];
public static double[] coordDoubleXY = new double[]{0.0, 0.0};
- static EntityPicker ep = new EntityPicker();
+ public static Integer[] coordInteger = new Integer[]{0, 0};
public static double[] graphicCoord = new double[3];
+ public static double[] datatipCoordinates = new double[2];
+ static EntityPicker ep = new EntityPicker();
public static String newDatatip = null;
public static String newMarker = null;
public static String createDatatip(String figureUid, Integer coordIntX, Integer coordIntY) {
Integer[] pixelMouseCoordInt = { coordIntX , coordIntY };
+ String polylineUid = ep.pick (figureUid, coordIntX, coordIntY);
String axesUid = datatipAxesHandler(figureUid, pixelMouseCoordInt);
double[] pixelMouseCoordDouble = transformPixelCoordToDouble(pixelMouseCoordInt);
graphicCoord = transformPixelCoordToGraphic(axesUid, pixelMouseCoordDouble);
+ insertPoint (polylineUid, graphicCoord[0], graphicCoord[1]);
String newDatatip = datatipProperties (graphicCoord, axesUid);
return newDatatip;
}
posMin = j;
}
}
-
String newDatatip = createDatatipProgramIndex(polylineUid, posMin+1);
return newDatatip;
} else {
int middleLineFactor = 0;
-
- double[] graphCoordDouble = new double[]{0.0, 0.0, 0.0};
- graphCoordDouble[0] = coordDoubleXY[0];
- graphCoordDouble[1] = coordDoubleXY[1];
- graphCoordDouble[2] = 0.0;
-
- double[] pixelCoordinates = new double[]{0.0, 0.0};
- pixelCoordinates = CallRenderer.getPixelFrom2dViewCoordinates(axesUid, graphCoordDouble);
-
- int xInt = (int) pixelCoordinates[0];
- int yInt = (int) pixelCoordinates[1];
-
- Integer[] coordInteger = new Integer[]{0, 0};
- coordInteger[0] = (Integer) xInt;
- coordInteger[1] = (Integer) yInt;
-
+ coordInteger = getDatatipPositionInteger (coordDoubleXY, axesUid);
int yVerify = 0;
Integer[] axesDimension = new Integer[]{0, 0};
axesDimension = (Integer[])GraphicController.getController().getProperty(figureUid, GraphicObjectProperties.__GO_AXES_SIZE__);
pixelMouseCoordInt[0] = newX;
pixelMouseCoordInt[1] = newY;
- double[] pixelMouseCoordDouble = new double[]{0.0, 0.0};
pixelMouseCoordDouble = transformPixelCoordToDouble(pixelMouseCoordInt);
- double[] graphicCoord = new double[]{0.0, 0.0, 0.0};
graphicCoord = transformPixelCoordToGraphic (axesUid, pixelMouseCoordDouble);
+ insertPoint (polylineUid, graphicCoord[0], graphicCoord[1]);
newDatatip = datatipProperties (graphicCoord, axesUid);
newMarker = MarkerCreate.markerProperties (graphicCoord, axesUid);
return newDatatip;
} else {
-
+ insertPoint (polylineUid, coordDoubleXY[0], coordDoubleXY[1]);
newDatatip = datatipProperties (coordDoubleXY, axesUid);
newMarker = MarkerCreate.markerProperties (coordDoubleXY, axesUid);
return newDatatip;
}
+ public static double[] createDatatipField (String polylineUid, double[] coordDoubleXY) {
+
+ double[] fieldArray = new double[coordDoubleXY.length];
+
+ String compoundUid = (String) GraphicController.getController().getProperty(polylineUid, GraphicObjectProperties.__GO_PARENT__);
+ String axesUid = (String) GraphicController.getController().getProperty(compoundUid, GraphicObjectProperties.__GO_PARENT__);
+ String figureUid = (String) GraphicController.getController().getProperty(axesUid, GraphicObjectProperties.__GO_PARENT__);
+
+ String[] childrenUid = (String[]) GraphicController.getController().getProperty(axesUid, GraphicObjectProperties.__GO_CHILDREN__);
+ for (int i = 0 ; i < childrenUid.length ; i++) {
+ String objType = (String) GraphicController.getController().getProperty(childrenUid[i], GraphicObjectProperties.__GO_TYPE__);
+ if (objType == "Text") {
+ Double[] datatipPosition = (Double[]) GraphicController.getController().getProperty(childrenUid[i], GraphicObjectProperties.__GO_POSITION__);
+ double[] doublePosition = new double[datatipPosition.length];
+ for (int j = 0 ; j < datatipPosition.length ; j++) {
+ doublePosition[j] = (double) datatipPosition[j];
+ }
+ coordInteger = getDatatipPositionInteger (doublePosition, axesUid);
+ String polylineUidEnd = ep.pick (figureUid, coordInteger[0], coordInteger[1]);
+ if (polylineUidEnd.equals(polylineUid)) {
+ GraphicController.getController().removeRelationShipAndDelete(childrenUid[i]);
+ }
+ }
+ }
+
+ for (int i = 0 ; i < (coordDoubleXY.length / 2) ; i++) {
+ datatipCoordinates[0] = coordDoubleXY[2*i];
+ datatipCoordinates[1] = coordDoubleXY[2*i + 1];
+
+ int middleLineFactor = 0;
+ coordInteger = getDatatipPositionInteger (datatipCoordinates, axesUid);
+ int yVerify = 0;
+ Integer[] axesDimension = new Integer[]{0, 0};
+ axesDimension = (Integer[])GraphicController.getController().getProperty(figureUid, GraphicObjectProperties.__GO_AXES_SIZE__);
+
+ String polylineUidEnd = null;
+ for (yVerify = 0 ; yVerify < axesDimension[1] ; yVerify++) {
+ polylineUidEnd = ep.pick (figureUid, coordInteger[0], yVerify);
+ if (polylineUidEnd != null) {
+ if (polylineUidEnd.equals(polylineUid)) {
+ middleLineFactor++;
+ }
+ }
+ }
+
+ if (middleLineFactor < 20) {
+
+ for (yVerify = 0 ; yVerify < axesDimension[1] ; yVerify++) {
+ polylineUidEnd = ep.pick (figureUid, coordInteger[0], yVerify);
+ if (polylineUidEnd != null) {
+ if (polylineUidEnd.equals(polylineUid)) {
+ break;
+ }
+ }
+ }
+
+ Integer newX = 0;
+ Integer newY = 0;
+ newX = coordInteger[0];
+ newY = yVerify + (middleLineFactor / 2);
+
+ Integer[] pixelMouseCoordInt = new Integer[]{0, 0};
+ pixelMouseCoordInt[0] = newX;
+ pixelMouseCoordInt[1] = newY;
+
+ pixelMouseCoordDouble = transformPixelCoordToDouble(pixelMouseCoordInt);
+
+ graphicCoord = transformPixelCoordToGraphic (axesUid, pixelMouseCoordDouble);
+
+ newDatatip = datatipProperties (graphicCoord, axesUid);
+ newMarker = MarkerCreate.markerProperties (graphicCoord, axesUid);
+ fieldArray[i] = graphicCoord[0];
+ fieldArray[i + (coordDoubleXY.length / 2)] = graphicCoord[1];
+
+ } else {
+ graphicCoord[0] = datatipCoordinates[0];
+ graphicCoord[1] = datatipCoordinates[1];
+ newDatatip = datatipProperties (graphicCoord, axesUid);
+ newMarker = MarkerCreate.markerProperties (graphicCoord, axesUid);
+ fieldArray[i] = datatipCoordinates[0];
+ fieldArray[i + (coordDoubleXY.length / 2)] = datatipCoordinates[1];
+ }
+ }
+
+ return fieldArray;
+ }
+
/**
* Given an integer index that belongs to the polyline create a datatip.
*
}
coordDoubleXY[0] = DataX[indexPoint - 1];
coordDoubleXY[1] = DataY[indexPoint - 1];
+ insertPoint (polylineUid, coordDoubleXY[0], coordDoubleXY[1]);
String newDatatip = datatipProperties (coordDoubleXY, axesUid);
String newMarker = MarkerCreate.markerProperties (coordDoubleXY, axesUid);
return newDatatip;
}
/**
+ * Get integer datatip position on a specific axes
+ *
+ * @param coordinates Datatip coordinates x, y in double precision
+ * @param axesUid Axes unique identifier
+ * @return integer datatip position
+ */
+ public static Integer[] getDatatipPositionInteger (double[] coordinates, String axesUid) {
+
+ double[] graphCoordDouble = new double[]{0.0, 0.0, 0.0};
+ graphCoordDouble[0] = coordinates[0];
+ graphCoordDouble[1] = coordinates[1];
+ graphCoordDouble[2] = 0.0;
+
+ double[] pixelCoordinates = new double[]{0.0, 0.0};
+ pixelCoordinates = CallRenderer.getPixelFrom2dViewCoordinates(axesUid, graphCoordDouble);
+
+ int xInt = (int) pixelCoordinates[0];
+ int yInt = (int) pixelCoordinates[1];
+
+ coordInteger[0] = (Integer) xInt;
+ coordInteger[1] = (Integer) yInt;
+
+ return coordInteger;
+ }
+
+ /**
* Get the axes handler of the figure which mouse click belongs
*
* @param figureUid Figure unique identifier.
GraphicController.getController().setProperty(polylineUid, GraphicObjectProperties.__GO_TAG__, interpString);
}
}
+
+ /**
+ * Insert the coordinates of a created datatip in the datatips field in the polyline
+ *
+ * @param polylineUid Polyline handler string.
+ * @param coordX Coordinate x of the datatip.
+ * @param coordY Coordinate y of the datatip.
+ */
+ private static void insertPoint (String polylineUid, double coordX, double coordY) {
+
+ Double[] currentDatatips = (Double[]) GraphicController.getController().getProperty(polylineUid, GraphicObjectProperties.__GO_DATATIPS__);
+ Integer numDatatips = (Integer) GraphicController.getController().getProperty(polylineUid, GraphicObjectProperties.__GO_DATATIPS_SIZE__);
+ int allocArray = (2*numDatatips) + 2;
+ Double[] newDatatips = new Double[allocArray];
+ int j = 0;
+ for (int i = 0 ; i < newDatatips.length ; i++) {
+ if (i == numDatatips) {
+ newDatatips[i] = coordX;
+ } else if (i == (newDatatips.length - 1)) {
+ newDatatips[i] = coordY;
+ } else {
+ newDatatips[i] = currentDatatips[j];
+ j++;
+ }
+ }
+ GraphicController.getController().setProperty(polylineUid, GraphicObjectProperties.__GO_DATATIPS__, newDatatips);
+ }
}
import org.scilab.modules.graphic_objects.graphicObject.GraphicObject;
import org.scilab.modules.graphic_objects.graphicObject.GraphicObjectProperties;
-import java.util.ArrayList;
+import org.scilab.modules.renderer.CallRenderer;
+
+import org.scilab.modules.gui.editor.EntityPicker;
/**
* Delete a datatip
*/
public class DatatipDelete {
+ static EntityPicker ep = new EntityPicker();
+
/**
- * Delete a specific datatip;
+ * Delete a specific datatip using the right mouse click;
*
* @param markerUid Datatip marker unique identifier.
*/
public static void deleteDatatip (String markerUid) {
- String parentUid = (String) GraphicController.getController().getProperty(markerUid, GraphicObjectProperties.__GO_PARENT__);
- String[] childrenUid = (String[]) GraphicController.getController().getProperty(parentUid, GraphicObjectProperties.__GO_CHILDREN__);
+ String axesUid = (String) GraphicController.getController().getProperty(markerUid, GraphicObjectProperties.__GO_PARENT__);
+ String figureUid = (String) GraphicController.getController().getProperty(axesUid, GraphicObjectProperties.__GO_PARENT__);
+
+ Double[] datatipPosition = (Double[]) GraphicController.getController().getProperty(markerUid, GraphicObjectProperties.__GO_POSITION__);
+
+ double[] graphCoordDouble = new double[]{0.0, 0.0, 0.0};
+ graphCoordDouble[0] = datatipPosition[0];
+ graphCoordDouble[1] = datatipPosition[1];
+ graphCoordDouble[2] = datatipPosition[2];
+
+ String polylineUid = getPolylineOfDatatip (graphCoordDouble, markerUid);
+
+ String[] childrenUid = (String[]) GraphicController.getController().getProperty(axesUid, GraphicObjectProperties.__GO_CHILDREN__);
for (int i = 0 ; i < childrenUid.length ; i++) {
if (markerUid == childrenUid[i]) {
GraphicController.getController().removeRelationShipAndDelete(childrenUid[i]);
GraphicController.getController().removeRelationShipAndDelete(childrenUid[i + 1]);
+ removePoint (polylineUid, graphCoordDouble[0], graphCoordDouble[1]);
}
}
}
+ /**
+ * Delete a specific datatip using the command "datatipRemove(polyline_handle,ind)";
+ *
+ * @param polylineUid Polyline unique identifier.
+ * @param indexRemove Index of the datatip to be removed.
+ */
public static void datatipRemoveProgramIndex (String polylineUid, int indexRemove) {
int numDatatips = 0;
int indexDel = (2 * indexRemove) - 1;
String datatipUid = childrenUid[indexDel];
String markerUid = childrenUid[indexDel - 1];
+ Double[] datatipPosition = (Double[]) GraphicController.getController().getProperty(markerUid, GraphicObjectProperties.__GO_POSITION__);
+ removePoint (polylineUid, datatipPosition[0], datatipPosition[1]);
GraphicController.getController().removeRelationShipAndDelete(datatipUid);
GraphicController.getController().removeRelationShipAndDelete(markerUid);
+
}
+
}
+ /**
+ * Delete a specific datatip using the command "datatipRemove(datatip_handle)";
+ *
+ * @param datatipUid Datatip unique identifier.
+ * @param figureUid Figure unique identifier.
+ */
public static void datatipRemoveProgramHandler (String datatipUid, String figureUid) {
int posDelete = -1;
+ String axesUid = null;
String[] childrenUid = (String[]) GraphicController.getController().getProperty(figureUid, GraphicObjectProperties.__GO_CHILDREN__);
- String axesUid = childrenUid[0];
- childrenUid = (String[]) GraphicController.getController().getProperty(axesUid, GraphicObjectProperties.__GO_CHILDREN__);
- String objType = (String) GraphicController.getController().getProperty(datatipUid, GraphicObjectProperties.__GO_TYPE__);
- if (objType == "Text") {
- for (int i = 0 ; i < childrenUid.length ; i++) {
- if (datatipUid == childrenUid[i]) {
- posDelete = i;
+ for (int i = 0 ; i < childrenUid.length ; i++) {
+ String objType = (String) GraphicController.getController().getProperty(childrenUid[i], GraphicObjectProperties.__GO_TYPE__);
+ if (objType == "Axes") {
+ axesUid = childrenUid[i];
+ }
+ }
+ if (axesUid != null){
+ childrenUid = (String[]) GraphicController.getController().getProperty(axesUid, GraphicObjectProperties.__GO_CHILDREN__);
+ String objType = (String) GraphicController.getController().getProperty(datatipUid, GraphicObjectProperties.__GO_TYPE__);
+ if (objType == "Text") {
+ for (int i = 0 ; i < childrenUid.length ; i++) {
+ if (datatipUid.equals(childrenUid[i])) {
+ posDelete = i;
+ }
+ }
+ }
+ if (posDelete >= 0) {
+ Double[] datatipPosition = (Double[]) GraphicController.getController().getProperty(datatipUid, GraphicObjectProperties.__GO_POSITION__);
+ double[] graphCoordDouble = new double[]{0.0, 0.0, 0.0};
+ graphCoordDouble[0] = datatipPosition[0];
+ graphCoordDouble[1] = datatipPosition[1];
+ graphCoordDouble[2] = datatipPosition[2];
+ String polylineUid = getPolylineOfDatatip (graphCoordDouble, datatipUid);
+ removePoint (polylineUid, datatipPosition[0], datatipPosition[1]);
+ GraphicController.getController().removeRelationShipAndDelete(childrenUid[posDelete]);
+ if (posDelete % 2 == 0) {
+ GraphicController.getController().removeRelationShipAndDelete(childrenUid[posDelete + 1]);
+ } else {
+ GraphicController.getController().removeRelationShipAndDelete(childrenUid[posDelete - 1]);
}
}
}
- if (posDelete >= 0) {
- GraphicController.getController().removeRelationShipAndDelete(childrenUid[posDelete]);
- if (posDelete % 2 == 0) {
- GraphicController.getController().removeRelationShipAndDelete(childrenUid[posDelete + 1]);
+ }
+
+ /**
+ * Get the polyline which the datatip belongs
+ *
+ * @param graphCoordDouble double array with graphic position x and y of the datatip.
+ * @param datatipUid Datatip unique identifier.
+ * @return Polyline unique identifier string.
+ */
+ private static String getPolylineOfDatatip (double[] graphCoordDouble, String datatipUid) {
+
+ String axesUid = (String) GraphicController.getController().getProperty(datatipUid, GraphicObjectProperties.__GO_PARENT__);
+ String figureUid = (String) GraphicController.getController().getProperty(axesUid, GraphicObjectProperties.__GO_PARENT__);
+
+ double[] pixelCoordinates = new double[]{0.0, 0.0};
+ pixelCoordinates = CallRenderer.getPixelFrom2dViewCoordinates(axesUid, graphCoordDouble);
+
+ int xInt = (int) pixelCoordinates[0];
+ int yInt = (int) pixelCoordinates[1];
+
+ Integer[] coordInteger = new Integer[]{0, 0};
+ coordInteger[0] = (Integer) xInt;
+ coordInteger[1] = (Integer) yInt;
+
+ String polylineUid = ep.pick (figureUid, coordInteger[0], coordInteger[1]);
+
+ return polylineUid;
+ }
+
+ /**
+ * Remove the point of the deleted datatip from the datatips field;
+ *
+ * @param polylineUid Polyline unique identifier.
+ * @param coordX Coordinate x to be removed.
+ * @param coordY Coordinate y to be removed.
+ */
+ private static void removePoint (String polylineUid, double coordX, double coordY) {
+
+ Double[] currentDatatips = (Double[]) GraphicController.getController().getProperty(polylineUid, GraphicObjectProperties.__GO_DATATIPS__);
+ Integer numDatatips = (Integer) GraphicController.getController().getProperty(polylineUid, GraphicObjectProperties.__GO_DATATIPS_SIZE__);
+ int xSkip = -1;
+ int ySkip = -1;
+ if (numDatatips > 0) {
+ int allocArray = (2*numDatatips) - 2;
+ Double[] newDatatips = new Double[allocArray];
+ if (allocArray == 0) {
+ GraphicController.getController().setProperty(polylineUid, GraphicObjectProperties.__GO_DATATIPS__, newDatatips);
} else {
- GraphicController.getController().removeRelationShipAndDelete(childrenUid[posDelete - 1]);
+ for (int i = 0 ; i < currentDatatips.length ; i++) {
+ if (currentDatatips[i] == coordX & currentDatatips[i+numDatatips] == coordY) {
+ xSkip = i;
+ ySkip = i+numDatatips;
+ break;
+ }
+ }
+ int j = 0;
+ for (int i = 0 ; i < currentDatatips.length ; i++) {
+ if (i != xSkip & i != ySkip) {
+ newDatatips[j] = currentDatatips[i];
+ j++;
+ }
+ }
+ GraphicController.getController().setProperty(polylineUid, GraphicObjectProperties.__GO_DATATIPS__, newDatatips);
}
}
}
String[] axesChildrenUid = (String[]) GraphicController.getController().getProperty(axesUid, GraphicObjectProperties.__GO_CHILDREN__);
coordInteger = DatatipMove.getCoordInteger (markerUid, axesUid);
polylineUidInit = ep.pick(figureUid, coordInteger[0], coordInteger[1]);
-
Boolean isLineModeOn = (Boolean) GraphicController.getController().getProperty(polylineUidInit, GraphicObjectProperties.__GO_LINE_MODE__);
Integer[] axesDimension = (Integer[])GraphicController.getController().getProperty(figureUid, GraphicObjectProperties.__GO_AXES_SIZE__);
for (int yVerify = 0 ; yVerify < axesDimension[1] ; yVerify++) {
Integer[] pixelMouseCoordInt = { newX , newY };
double[] pixelMouseCoordDouble = DatatipCreate.transformPixelCoordToDouble(pixelMouseCoordInt);
double[] graphicCoord = DatatipCreate.transformPixelCoordToGraphic (axesUid, pixelMouseCoordDouble);
- setNewPosition (graphicCoord, markerUid, axesUid);
+ setNewPosition (graphicCoord, markerUid, axesUid, polylineUidInit);
} else {
Integer[] pixelMouseCoordInt = { newX , newY };
double[] pixelMouseCoordDouble = DatatipCreate.transformPixelCoordToDouble(pixelMouseCoordInt);
if (graphicCoord[0] > polylineDataX[i - 1] & graphicCoord[0] < polylineDataX[i + 1]) {
newCoord[0] = polylineDataX[i];
newCoord[1] = polylineDataY[i];
- setNewPosition (newCoord, markerUid, axesUid);
+ setNewPosition (newCoord, markerUid, axesUid, polylineUidInit);
}
}
}
* @param indexToMove Integer referring to the selected datatip.
* @return New position of the datatip to be saved
*/
- private static void setNewPosition (double[] graphicCoord, String markerUid, String axesUid) {
+ private static void setNewPosition (double[] graphicCoord, String markerUid, String axesUid, String polylineUid) {
String[] axesChildrenUid = (String[]) GraphicController.getController().getProperty(axesUid, GraphicObjectProperties.__GO_CHILDREN__);
-
for (int i = 0 ; i < axesChildrenUid.length ; i++) {
if (axesChildrenUid[i] == markerUid) {
datatipUid = axesChildrenUid[i + 1];
break;
}
}
-
+ Double[] datatipPosition = (Double[]) GraphicController.getController().getProperty(markerUid, GraphicObjectProperties.__GO_POSITION__);
+ DatatipMove.updateDatatipsField (polylineUid, datatipPosition[0], datatipPosition[1], graphicCoord[0], graphicCoord[1]);
datatipPosition = DatatipCreate.setDatatipPosition(graphicCoord);
GraphicController.getController().setProperty(datatipUid, GraphicObjectProperties.__GO_POSITION__, datatipPosition);
GraphicController.getController().setProperty(markerUid, GraphicObjectProperties.__GO_POSITION__, datatipPosition);
}
}
setNewPosition (datatipUid, markerUid, newX, newY);
+ updateDatatipsField (polylineUid, coordsToMove[0], coordsToMove[1], newX, newY);
}
/**
}
}
setNewPosition (datatipUid, markerUid, newX, newY);
+ updateDatatipsField (polylineUid, coordsToMove[0], coordsToMove[1], newX, newY);
}
+ /**
+ * Get the pixel integer coordinates of a datatip
+ *
+ * @param markerUid Datatip's marker unique identifier
+ * @param axesUid Axes unique identifier which the datatip belongs
+ * @return Array with x, y coordinates
+ */
public static Integer[] getCoordInteger (String markerUid, String axesUid) {
Double[] markerPosition = (Double[]) GraphicController.getController().getProperty(markerUid, GraphicObjectProperties.__GO_POSITION__);
return coordInteger;
}
+ /**
+ * Set the new position of a datatip and its label after moved
+ *
+ * @param datatipUid Datatip unique identifier.
+ * @param markerUid Datatip's marker unique identifier.
+ * @param newX New position x of the datatip
+ * @param newX New position y of the datatip
+ */
private static void setNewPosition (String datatipUid, String markerUid, double newX, double newY) {
double[] newPosition = { newX , newY , 0.0 };
GraphicController.getController().setProperty(markerUid, GraphicObjectProperties.__GO_POSITION__, datatipPosition);
}
+ /**
+ * Update the datatips field in the polyline handler after move
+ *
+ * @param polylineUid Polyline unique identifier.
+ * @param oldX Current position x of the datatip
+ * @param oldY Current position y of the datatip
+ * @param newX New position x of the datatip
+ * @param newX New position y of the datatip
+ */
+ public static void updateDatatipsField (String polylineUid, double oldX, double oldY, double newX, double newY) {
+
+ Double[] currentDatatips = (Double[]) GraphicController.getController().getProperty(polylineUid, GraphicObjectProperties.__GO_DATATIPS__);
+ Integer numDatatips = (Integer) GraphicController.getController().getProperty(polylineUid, GraphicObjectProperties.__GO_DATATIPS_SIZE__);
+ for (int i = 0 ; i < currentDatatips.length ; i++) {
+ if (currentDatatips[i] == oldX & currentDatatips[i+numDatatips] == oldY) {
+ currentDatatips[i] = newX;
+ currentDatatips[i+numDatatips] = newY;
+ break;
+ }
+ }
+ GraphicController.getController().setProperty(polylineUid, GraphicObjectProperties.__GO_DATATIPS__, currentDatatips);
+ }
+
}
<parameter name="polylineUid" type="String"/>
<parameter name="coordDoubleXY" type="double[]"/>
</method>
+ <method name="createDatatipField" returnType="double[]" modifier="static">
+ <parameter name="polylineUid" type="String"/>
+ <parameter name="coordDoubleXY" type="double[]"/>
+ </method>
<method name="createDatatipProgramIndex" returnType="String" modifier="static">
<parameter name="polylineUid" type="String"/>
<parameter name="indexPoint" type="int"/>
#include "DatatipFunctions.hxx"
/* Generated by GIWS (version 2.0.0) with command:
-giws -f Datatip.giws.xml -p
+giws -f Datatip.giws.xml -p -r
*/
/*
/* Methods ID set to NULL */
jstringcreateDatatipProgramCoordjstringjava_lang_StringjdoubleArray_doubledoubleID=NULL;
+jdoubleArray_createDatatipFieldjstringjava_lang_StringjdoubleArray_doubledoubleID=NULL;
jstringcreateDatatipProgramIndexjstringjava_lang_StringjintintID=NULL;
voiddatatipSetInterpjstringjava_lang_StringjbooleanbooleanID=NULL;
}
/* Methods ID set to NULL */
jstringcreateDatatipProgramCoordjstringjava_lang_StringjdoubleArray_doubledoubleID=NULL;
+jdoubleArray_createDatatipFieldjstringjava_lang_StringjdoubleArray_doubledoubleID=NULL;
jstringcreateDatatipProgramIndexjstringjava_lang_StringjintintID=NULL;
voiddatatipSetInterpjstringjava_lang_StringjbooleanbooleanID=NULL;
}
+double* DatatipCreate::createDatatipField (JavaVM * jvm_, char const* polylineUid, double const* coordDoubleXY, int coordDoubleXYSize){
+
+JNIEnv * curEnv = NULL;
+jvm_->AttachCurrentThread(reinterpret_cast<void **>(&curEnv), NULL);
+jclass cls = curEnv->FindClass( className().c_str() );
+
+jmethodID jdoubleArray_createDatatipFieldjstringjava_lang_StringjdoubleArray_doubledoubleID = curEnv->GetStaticMethodID(cls, "createDatatipField", "(Ljava/lang/String;[D)[D" ) ;
+if (jdoubleArray_createDatatipFieldjstringjava_lang_StringjdoubleArray_doubledoubleID == NULL) {
+std::cerr << "Could not access to the method " << "createDatatipField" << std::endl;
+curEnv->ExceptionDescribe();
+
+exit(EXIT_FAILURE);
+}
+
+jstring polylineUid_ = curEnv->NewStringUTF( polylineUid );
+if (polylineUid != NULL && polylineUid_ == NULL)
+{
+std::cerr << "Could not convert C string to Java UTF string, memory full." << std::endl;
+exit(EXIT_FAILURE);
+}
+
+
+jdoubleArray coordDoubleXY_ = curEnv->NewDoubleArray( coordDoubleXYSize ) ;
+
+curEnv->SetDoubleArrayRegion( coordDoubleXY_, 0, coordDoubleXYSize, (jdouble*)(coordDoubleXY) ) ;
+
+
+ jdoubleArray res = static_cast<jdoubleArray>( curEnv->CallStaticObjectMethod(cls, jdoubleArray_createDatatipFieldjstringjava_lang_StringjdoubleArray_doubledoubleID ,polylineUid_, coordDoubleXY_));
+ if (res == NULL) { return NULL; }
+ if (curEnv->ExceptionCheck()) {
+curEnv->ExceptionDescribe() ;
+}
+int lenRow;
+ lenRow = curEnv->GetArrayLength(res);
+jboolean isCopy = JNI_FALSE;
+
+/* GetPrimitiveArrayCritical is faster than getXXXArrayElements */
+jdouble *resultsArray = static_cast<jdouble *>(curEnv->GetPrimitiveArrayCritical(res, &isCopy));
+double* myArray= new double[ lenRow];
+
+for (jsize i = 0; i < lenRow; i++){
+myArray[i]=resultsArray[i];
+}
+curEnv->ReleasePrimitiveArrayCritical(res, resultsArray, JNI_ABORT);
+
+ curEnv->DeleteLocalRef(res);
+curEnv->DeleteLocalRef(polylineUid_);
+curEnv->DeleteLocalRef(coordDoubleXY_);
+curEnv->DeleteLocalRef(cls);
+if (curEnv->ExceptionCheck()) {
+curEnv->ExceptionDescribe() ;
+}
+
+return myArray;
+
+}
+
char* DatatipCreate::createDatatipProgramIndex (JavaVM * jvm_, char const* polylineUid, int indexPoint){
JNIEnv * curEnv = NULL;
/* Generated by GIWS (version 2.0.0) with command:
-giws -f Datatip.giws.xml -p
+giws -f Datatip.giws.xml -p -r
*/
/*
protected:
jmethodID jstringcreateDatatipProgramCoordjstringjava_lang_StringjdoubleArray_doubledoubleID; // cache method id
+jmethodID jdoubleArray_createDatatipFieldjstringjava_lang_StringjdoubleArray_doubledoubleID; // cache method id
jmethodID jstringcreateDatatipProgramIndexjstringjava_lang_StringjintintID; // cache method id
jmethodID voiddatatipSetInterpjstringjava_lang_StringjbooleanbooleanID; // cache method id
// Methods
static char* createDatatipProgramCoord(JavaVM * jvm_, char const* polylineUid, double const* coordDoubleXY, int coordDoubleXYSize);
+static double* createDatatipField(JavaVM * jvm_, char const* polylineUid, double const* coordDoubleXY, int coordDoubleXYSize);
+
static char* createDatatipProgramIndex(JavaVM * jvm_, char const* polylineUid, int indexPoint);
static void datatipSetInterp(JavaVM * jvm_, char const* polylineUid, bool interpMode);