GET_FILENAME_COMPONENT(SIP_ROOT ${SIP_ROOT} PATH)
ENDIF(SIP_ROOT)
-IF(WINDOWS)
- SET(SIP_INCLUDES -I${SIP_ROOT}/include)
-ELSE(WINDOWS)
- SET(SIP_INCLUDES -I${SIP_ROOT}/include/python${PYTHON_VERSION})
-ENDIF(WINDOWS)
+SET(SIP_INCLUDES -I${SIP_ROOT}/include/python${PYTHON_VERSION})
IF(WINDOWS)
FIND_PROGRAM(PYUIC_EXECUTABLE NAMES pyuic4 pyuic4.bat)
FIND_LIBRARY(vtkCommonPythonD vtkCommonPythonD ${VTK_LIBRARY_DIRS} NO_DEFAULT_PATH)
FIND_LIBRARY(vtkGraphicsPythonD vtkGraphicsPythonD ${VTK_LIBRARY_DIRS} NO_DEFAULT_PATH)
FIND_LIBRARY(vtkImagingPythonD vtkImagingPythonD ${VTK_LIBRARY_DIRS} NO_DEFAULT_PATH)
+FIND_LIBRARY(vtkPythonCore vtkPythonCore ${VTK_LIBRARY_DIRS} NO_DEFAULT_PATH)
+
#IF(NOT WINDOWS)
# IF(VTK_MAJOR_VERSION STREQUAL 5)
#!/bin/bash -f
+
# Copyright (C) 2007-2011 CEA/DEN, EDF R&D, OPEN CASCADE
#
# Copyright (C) 2003-2007 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
# File : runLightSalome.sh
# Author : Vadim SANDLER, Open CASCADE S.A.S, vadim.sandler@opencascade.com
+
+
###
-# set default value for the LightAppConfig variable, which
-# is necessary for loading of .ini or .xml resources file
+# function show_usage() : print help an exit
###
-#
-if [ -z "$LightAppConfig" ] ; then
- export LightAppConfig=${GUI_ROOT_DIR}/share/salome/resources/gui
-else
- export LightAppConfig=${LightAppConfig}:${GUI_ROOT_DIR}/share/salome/resources/gui
-fi
-if [ -z "$LightAppResources" ] ; then
- export LightAppResources=${GUI_ROOT_DIR}/share/salome/resources/gui
-else
- export LightAppResources=${LightAppResources}:${GUI_ROOT_DIR}/share/salome/resources/gui
-fi
+
+show_usage() {
+ local RET=0
+ if [ $# -gt 0 ] ; then RET=$1 ; fi
+ local MOVE1="echo -en \\033[35G"
+ local MOVE2="echo -en \\033[22G"
+ echo
+ echo "Run standalone SALOME desktop".
+ echo
+ echo "Usage: $(basename $0) [options]"
+ echo
+ echo "Options:"
+ echo " * all options have both short and long format;"
+ echo " * some options require additional parameter (below referenced as <param>)"
+ echo " which should be separated by = symbol from the option itself."
+ echo
+ echo -en " --help"
+ ${MOVE2} ; echo -en "(-h)"
+ ${MOVE1} ; echo "Display this information and exit."
+ echo -en " --version"
+ ${MOVE2} ; echo -en "(-v)"
+ ${MOVE1} ; echo "Print SALOME version and exit."
+ echo -en " --modules=<param>"
+ ${MOVE2} ; echo -en "(-m)"
+ ${MOVE1} ; echo "List of modules, separated by comma, to be used within SALOME session."
+ echo
+ echo "Example:"
+ echo " $(basename $0) --modules=LIGHT,PYLIGHT"
+ echo
+ exit ${RET}
+}
###
-# process --modules=... command line option (get list of modules)
+# function show_version() : print SALOME version an exit
###
-modules=""
-
-for arg in X $* ; do
- if [ "$arg" != "X" ] ; then
- case $arg in
- --modules=* ) modules=`echo $arg | awk -F= '{ print $2 }' | sed -e "s%,% %g"` ;;
- *) ;;
- esac
+show_version() {
+ local RET=0
+ local DIR=$(dirname $0)
+ if [ -z "${DIR}" ] ; then DIR=. ; fi
+ if [ -f ${DIR}/VERSION ] ; then
+ cat ${DIR}/VERSION
+ else
+ echo
+ echo "Error: can't find VERSION file" > /dev/stderr
+ echo
+ RET=1
fi
-done
-
-modules="KERNEL GUI $modules"
+ exit ${RET}
+}
###
-# exclude modules duplication
+# function option_modules() : process --modules / -m command line option
###
-mods=""
-
-for mod in $modules ; do
- echo $mods | grep -E "\<$mod\>" >/dev/null 2>&1
- if [ "$?" == "1" ] ; then
- mods="$mods $mod"
+option_modules() {
+ local MODS=`echo $1 | awk -F "=" '{ if(NF>1) print $2 ; else print $1 }'`
+ if [ "X${MODS}" = "X" ] ; then
+ echo
+ echo "Error: Please, specify list of modules" > /dev/stderr
+ echo
+ exit 1
fi
-done
+ MODULES=`echo ${MODS} | sed -e "s%,% %g"`
+ return
+}
+
###
-# set additional environment
+# function run_light_salome(): run SALOME
###
-python_version=`python -c "import sys; print sys.version[:3]" 2>/dev/null`
-
-MY_PATH=""
-MY_LD_LIBRARY_PATH=""
-MY_PYTHONPATH=""
-
-for mod in $mods ; do
- if [ "$arg" != "X" ] ; then
- root_dir=`printenv ${mod}_ROOT_DIR`
- if [ "$root_dir" != "" ] ; then
- mod_lower=`echo $mod | tr "A-Z" "a-z"`
- if [ -d ${root_dir}/bin/salome ] ; then
- if [ "${MY_PATH}" == "" ] ; then
- MY_PATH=${root_dir}/bin/salome
- else
- MY_PATH=${MY_PATH}:${root_dir}/bin/salome
- fi
- fi
- if [ -d ${root_dir}/lib/salome ] ; then
- if [ "${MY_LD_LIBRARY_PATH}" == "" ] ; then
- MY_LD_LIBRARY_PATH=${root_dir}/lib/salome
- else
- MY_LD_LIBRARY_PATH=${MY_LD_LIBRARY_PATH}:${root_dir}/lib/salome
- fi
+run_light_salome(){
+
+ local MODULES
+
+ ###
+ # process command line options
+ ###
+
+ local OPTION
+ while getopts ":-:hvm:" OPTION "$@" ; do
+ if [ "${OPTION}" = "-" ] ; then
+ case ${OPTARG} in
+ help ) show_usage ;;
+ version ) show_version ;;
+ modules* ) option_modules "${OPTARG}" ;;
+ * ) echo "!!!Wrong option!!!" ; exit 1 ;;
+ esac
+ else
+ case ${OPTION} in
+ h ) show_usage ;;
+ v ) show_version ;;
+ m* ) option_modules "${OPTARG}" ;;
+ ? ) echo "!!!Wrong option!!!" ; exit 1 ;;
+ esac
+ fi
+ done
+ shift $((OPTIND - 1))
+
+ ###
+ # by default try to detect all available modules
+ ###
+
+ if [ -z "${MODULES}" ] ; then
+ local ENVVAR
+ local ROOTDIR
+ for ENVVAR in `env | awk -F= '{print $1}' | grep _ROOT_DIR` ; do
+ local MOD=`echo $ENVVAR | awk -F_ '{print $1}'`
+ local LMOD=`echo ${MOD} | tr 'A-Z' 'a-z'`
+ ROOTDIR=`printenv ${ENVVAR}`
+ if [ -f ${ROOTDIR}/share/salome/resources/${LMOD}/LightApp.xml ] || [ -f ${ROOTDIR}/share/salome/resources/LightApp.xml ] ; then
+ MODULES="${MODULES} ${MOD}"
fi
- if [ "${python_version}" != "" ] ; then
- if [ -d ${root_dir}/bin/salome ] ; then
- if [ "${MY_PYTHONPATH}" == "" ] ; then
- MY_PYTHONPATH=${root_dir}/bin/salome
- else
- MY_PYTHONPATH=${MY_PYTHONPATH}:${root_dir}/bin/salome
- fi
- fi
- if [ -d ${root_dir}/lib/salome ] ; then
- if [ "${MY_PYTHONPATH}" == "" ] ; then
- MY_PYTHONPATH=${root_dir}/lib/salome
- else
- MY_PYTHONPATH=${MY_PYTHONPATH}:${root_dir}/lib/salome
- fi
- fi
- if [ -d ${root_dir}/lib/python${python_version}/site-packages/salome ] ; then
- if [ "${MY_PYTHONPATH}" == "" ] ; then
- MY_PYTHONPATH=${root_dir}/lib/python${python_version}/site-packages/salome
- else
- MY_PYTHONPATH=${MY_PYTHONPATH}:${root_dir}/lib/python${python_version}/site-packages/salome
- fi
- fi
+ done
+ fi
+
+ ###
+ # initial environment
+ ###
+
+ if [ -z "${LightAppResources}" ] ; then
+ export LightAppResources=${GUI_ROOT_DIR}/share/salome/resources/gui
+ else
+ export LightAppResources=${LightAppResources}:${GUI_ROOT_DIR}/share/salome/resources/gui
+ fi
+
+ MODULES="KERNEL GUI ${MODULES}"
+
+ ###
+ # exclude modules duplication
+ ###
+
+ local MODS=""
+ local MOD
+ for MOD in ${MODULES} ; do
+ echo ${MODS} | grep -E "\<${MOD}\>" >/dev/null 2>&1
+ if [ "$?" == "1" ] ; then
+ MODS="${MODS} ${MOD}"
+ fi
+ done
+ MODULES=${MODS}
+
+ ###
+ # set additional environment
+ ###
+
+ local PVERSION=`python -c "import sys; print sys.version[:3]" 2>/dev/null`
+
+ local MY_PATH=""
+ local MY_LD_LIBRARY_PATH=""
+ local MY_PYTHONPATH=""
+
+ for MOD in ${MODULES} ; do
+ local ROOTDIR=`printenv ${MOD}_ROOT_DIR`
+ if [ -z "${ROOTDIR}" ] ; then continue ; fi
+ local LMOD=`echo ${MOD} | tr 'A-Z' 'a-z'`
+ if [ -d ${ROOTDIR}/bin/salome ] ; then
+ MY_PATH=${MY_PATH}:${ROOTDIR}/bin/salome
+ fi
+ if [ -d ${ROOTDIR}/lib/salome ] ; then
+ MY_LD_LIBRARY_PATH=${MY_LD_LIBRARY_PATH}:${ROOTDIR}/lib/salome
+ fi
+ if [ "${PVERSION}" != "" ] ; then
+ if [ -d ${ROOTDIR}/bin/salome ] ; then
+ MY_PYTHONPATH=${MY_PYTHONPATH}:${ROOTDIR}/bin/salome
fi
- if [ "$mod" != "KERNEL" ] && [ "$mod" != "GUI" ] ; then
- export LightAppConfig=${LightAppConfig}:${root_dir}/share/salome/resources/${mod_lower}
+ if [ -d ${ROOTDIR}/lib/salome ] ; then
+ MY_PYTHONPATH=${MY_PYTHONPATH}:${ROOTDIR}/lib/salome
fi
- if [ "${SALOMEPATH}" == "" ] ; then
- export SALOMEPATH=${root_dir}
- else
- export SALOMEPATH=${SALOMEPATH}:${root_dir}
+ if [ -d ${ROOTDIR}/lib/python${PVERSION}/site-packages/salome ] ; then
+ MY_PYTHONPATH=${MY_PYTHONPATH}:${ROOTDIR}/lib/python${PVERSION}/site-packages/salome
fi
fi
- fi
-done
-
-if [ "${MY_PATH}" != "" ] ; then
- export PATH=${MY_PATH}:${PATH}
-fi
-if [ "${MY_LD_LIBRARY_PATH}" != "" ] ; then
- export LD_LIBRARY_PATH=${MY_LD_LIBRARY_PATH}${LD_LIBRARY_PATH:+:$LD_LIBRARY_PATH}
-fi
-if [ "${PYTHONPATH}" != "" ] ; then
- export PYTHONPATH=${MY_PYTHONPATH}:${PYTHONPATH}
-fi
+ if [ -f ${ROOTDIR}/share/salome/resources/${LMOD}/LightApp.xml ] ; then
+ export LightAppConfig=${LightAppConfig}:${ROOTDIR}/share/salome/resources/${LMOD}
+ elif [ -f ${ROOTDIR}/share/salome/resources/LightApp.xml ] ; then
+ export LightAppConfig=${LightAppConfig}:${ROOTDIR}/share/salome/resources
+ fi
+ export SALOMEPATH=${SALOMEPATH}:${ROOTDIR}
+ done
+
+ PATH=${MY_PATH}:${PATH}
+ PATH=`echo ${PATH} | sed -e "s,^:,,;s,:$,,;s,::\+,:,g"`
+ export PATH
+ LD_LIBRARY_PATH=${MY_LD_LIBRARY_PATH}:${LD_LIBRARY_PATH}
+ LD_LIBRARY_PATH=`echo ${LD_LIBRARY_PATH} | sed -e "s,^:,,;s,:$,,;s,::\+,:,g"`
+ export LD_LIBRARY_PATH
+ PYTHONPATH=${MY_PYTHONPATH}:${PYTHONPATH}
+ PYTHONPATH=`echo ${PYTHONPATH} | sed -e "s,^:,,;s,:$,,;s,::\+,:,g"`
+ export PYTHONPATH
+ LightAppConfig=`echo ${LightAppConfig} | sed -e "s,^:,,;s,:$,,;s,::\+,:,g"`
+ export LightAppConfig
+ SALOMEPATH=`echo ${SALOMEPATH} | sed -e "s,^:,,;s,:$,,;s,::\+,:,g"`
+ export SALOMEPATH
+
+ ###
+ # start application
+ ###
+
+ SUITApp LightApp "$*" &
+}
###
-# start application
+# call wrapper function (entry point)
###
-SUITApp LightApp $* &
+run_light_salome "$@"
\ No newline at end of file
# Modified by : Marc Tajchman (CEA)
# Modified by : Mikhail PONIKAROV (OCN) - autotools usage
#
-AC_INIT([Salome2 Project GUI module], [6.3.0], [webmaster.salome@opencascade.com], [SalomeGUI])
+AC_INIT([Salome2 Project GUI module], [6.3.1], [webmaster.salome@opencascade.com], [SalomeGUI])
AC_CONFIG_AUX_DIR(adm_local/unix/config_files)
AC_CANONICAL_HOST
AC_CANONICAL_TARGET
\image html occ_view_minimized.png
<br>
\image html occ_view_maximized.png
-<br><center><b>Minimize/Maximize</b> - these buttons allow switch
-current view area to the minimized / maximized state.</center>
+<br><center><b>Minimize/Maximize</b> - these buttons allow switching
+the current view area to the minimized / maximized state.</center>
<hr>
\note OCC Viewer features a special <b>Polyline Selection</b>
<ul>
<li><b>Language</b></li>
<ul>
-<li><b>Current language</b> - The application's resources language used.
-Note, that if you change the language, it will come in force only
-after application restarting.</li>
+<li><b>Current language</b> - The language used by the application GUI.
+The language change will come in force only after the application is restarted.</li>
</ul>
<li><b>Look and feel</b></li>
<ul>
<li><b>Opaque resize</b> - Force opaque resize mode for viewers area (tabbed workspace).
-Clear this check box for less perfomant stations.</li>
+Clear this checkbox for less perfomant workstations.</li>
</ul>
<li><b>Study Properties</b></li>
<ul>
saved with the rest of the data whenever you save the study. When the
study is reopened, the GUI state is restored.</li>
<li><b>Multi file python dump</b> - allows to generate multiple files
-(separately for each component) during the process of dumping study to python.
+(separately for each component) for dumping of a study to a python script.
If the option is disabled, the study is dumped to a single python script.</li>
</ul>
<li><b>External browser</b></li>
file.
- <b>Names of groups</b> - allows to specify parameters of the
titles displayed in the viewer:
- - <b>Text color</b> - titles text color
- - <b>Transparency</b> - titles transparency value
+ - <b>Text color</b> - allows selecting the text color;
+ - <b>Transparency</b> - allows selecting the text transparency.
- <b>Plot2d Viewer</b>
- <b>Show legend</b> - this options specifies if it's necessary to
show legend by default.
<li><b>Never</b> - automatic browsing is disabled.</li>
<li><b>After Apply & Close only</b> - browsing is activated when the
dialog is accepted by <b>Apply & Close</b> or <b>Ok</b> buttons (or if
-the objects are published as a result of an operation activated without
-using dialog at all - for example, by clicking some context menu button)
+the objects are published without using a dialog, for example, by
+clicking a context menu button)
and not activated when the <b>Apply</b> button is pressed and therefore
-dialog stays visible.</li>
+the dialog remains visible.</li>
<li><b>Always</b> - automatic browsing is always enabled.</li>
</ul>
</ul>
\page themes_page Theme
-\b Theme dialog is used for customization of the look and feel of
-Salome. To open it, select in the Main menu <b>View -> Theme </b>.
+The look-n-feel of the SALOME desktop can be customized by the user
+via the SALOME theme preferences.
+
+<b>SALOME style prefereces</b> dialog box is used for customization of
+the look and feel of SALOME style. To open it, select in the Main menu
+<b>View -> Theme </b> item.
+
+If SALOME theme is not used (<b>Use SALOME Style</b> check bos is
+switched off), the global system settings are applied (for
+example, those ones specified by the KDE settings).
+In such a way, the application's look-n-feel attributes (such as
+palette and/or font) can be customized by using of the Qt utility
+<em>qtconfig</em>.
+
+Alternatively look-n-feel of the application desktop can be customized
+using SALOME theme.
\image html theme1.png
-It is possible to choose a predefined color scheme in the list to the left
-or to edit your custom color scheme using the controls to the right.
+It is possible to choose a predefined scheme in the list to the left
+or create custom scheme using the controls to the right.
-\b Quick button allows to apply color change made in one position to all
-other positions using this color.
+The dialog box contains two pages.
+
+The first page allows specifying of the color palette.
+- \b Quick button allows automatic color palette definition basing on
+one main color specified by the user.
\image html theme2.png
-<ul>
-<li>\b Font group allows to edit the default font used in Salome menus.</li>
-<li>\b Lines group allows to apply dashing to Salome elements. </li>
-<li><b> Widgets rounding</b> allows to round corners of Salome dialog
-boxes and define their parameters.</li>
-<li>\b Handle allows to define parameters of the handle.</li>
-<li><b> Widget effect </b> allows to apply special effects to Salome
-dialog boxes.</li>
-</ul>
-*/
\ No newline at end of file
+The second page allows specifying different properties of the theme:
+
+- \b Font group allows to edit the font used in menus, dialog boxes, etc.
+- \b Lines group allows to apply dashing to Salome elements.
+- <b>Widgets rounding</b> allows to round corners of Salome dialog
+boxes and define their parameters.
+- \b Handle allows to define parameters of the handle.
+- <b>Widget effect</b> allows to apply special effects to Salome
+dialog boxes.
+
+*/
\image html vtk_view_parameters_dlg.png
<br>
-- <b>Projection Mode</b> - switch to the Orthogonal / Perspective
+- <b>Projection Mode</b> - switchs to the Orthogonal / Perspective
projection mode
- <b>Focal Point</b> - allows to specify the focal point of the view
- - <b>Set to Bounding Box Center</b> - chooses center of the current
- scence bounding box as a focal point
- - <b>Set to Origin</b> - chooses global coordinates system origin as
- a focal point
- - <b>Select Point from View</b> - allows specify focal point by the
- direct selection of some point in the view window
- - <b>X</b>, <b>Y</b>, <b>Z</b> - input coordinates of the focal
+ - <b>Set to Bounding Box Center</b> - chooses the center of the
+ bounding box of the current scene as the focal point.
+ - <b>Set to Origin</b> - chooses the global coordinates system origin as
+ the focal point
+ - <b>Select Point from View</b> - allows to specify the focal point by the
+ direct selection of a point in the view window
+ - <b>X</b>, <b>Y</b>, <b>Z</b> - allows to input the coordinates of the focal
point directly
-- <b>Camera Position</b> - allows to specify view camera's position:
- - <b>Absolute Coordinates</b> - either in absolute coordinates
- - <b>Relative to Focal Point</b> - or as a offset to the focal point
- - <b>Projection Direction</b> - allows specify direction of the
- projection vector
- - <b>Focal Distance</b> - focal distance value
- - <b>View Up Direction</b> - direction of the "view up" vector
-- <b>Zooming</b> - current zoom factor (available in the <b>Orthogonal
+- <b>Camera Position</b> - allows to specify the position of the view camera:
+ - <b>Absolute Coordinates</b> - either in absolute coordinates,
+ - <b>Relative to Focal Point</b> - or as a offset to the focal point;
+ - <b>Projection Direction</b> - allows specify the direction of the
+ projection vector;
+ - <b>Focal Distance</b> - the focal distance value;
+ - <b>View Up Direction</b> - direction of the "view up" vector.
+- <b>Zooming</b> - the current zoom factor (available in the <b>Orthogonal
mode</b> only)
-- <b>View Angle</b> - current view angle (available in the <b>Perspective
+- <b>View Angle</b> - the current view angle (available in the <b>Perspective
mode</b> only)
<hr>
\image html vtk_view_parallel.png
-<br><center><b>Orthogonal mode</b> - Switch view to the orthogonal mode.</center>
+<br><center><b>Orthogonal mode</b> - Switches the view to the orthogonal mode.</center>
<hr>
\image html vtk_view_perspective.png
-<br><center><b>Perspective mode</b> - Switch view to the perspective mode.</center>
+<br><center><b>Perspective mode</b> - Switches the view to the perspective mode.</center>
<hr>
\image html vtk_view_recording_start.png
\image html vtk_view_recording_stop.png
<br><center>These buttons allow recording viewing operations as a
video file in the AVI format using external software (jpeg2yuv):</center>
-- <b>Start recording</b> - specify parameters and start recording
-- <b>Pause recording</b> - suspend recording
-- <b>Continue recording</b> - resume recording
-- <b>Stop recording</b> - stop recording
+- <b>Start recording</b> - specify parameters and start recording;
+- <b>Pause recording</b> - suspend recording;
+- <b>Continue recording</b> - resume recording;
+- <b>Stop recording</b> - stop recording.
*/
if ( myModule )
{
+ // VSR: 26/06/2011 bug 0021307: temporarily disable desktop's signals to prevent false module activation
+ bool signalsBlocked = desktop() && desktop()->signalsBlocked();
+ if ( desktop() ) desktop()->blockSignals( true );
if ( !myModule->deactivateModule( activeStudy() ) )
{
// ....
}
+ // VSR: 26/06/2011 bug 0021307: enable desktop's signals back
+ if ( desktop() ) desktop()->blockSignals( signalsBlocked );
}
myModule = mod;
QVariant& aResult = theDefValue;
ViewMgrMap::ConstIterator v_it = myViewMgrMap.find(theViewMgrId);
if(v_it != myViewMgrMap.end()){
- const ObjMap& anOnjectMap = v_it.value();
- ObjMap::ConstIterator o_it = anOnjectMap.find(theEntry);
- if(o_it != anOnjectMap.end()) {
+ const ObjMap& anObjectMap = v_it.value();
+ ObjMap::ConstIterator o_it = anObjectMap.find(theEntry);
+ if(o_it != anObjectMap.end()) {
const PropMap& aPropMap = o_it.value();
PropMap::ConstIterator p_it = aPropMap.find(thePropName);
if(p_it != aPropMap.end()) {
*/
const PropMap& LightApp_Study::getObjectPropMap(int theViewMgrId, QString theEntry) {
ViewMgrMap::Iterator v_it = myViewMgrMap.find(theViewMgrId);
- if(v_it != myViewMgrMap.end()){
- ObjMap& anOnjectMap = v_it.value();
- ObjMap::Iterator o_it = anOnjectMap.find(theEntry);
- if(o_it != anOnjectMap.end()) {
+ if (v_it != myViewMgrMap.end()) {
+ ObjMap& anObjectMap = v_it.value();
+ ObjMap::Iterator o_it = anObjectMap.find(theEntry);
+ if(o_it != anObjectMap.end()) {
return o_it.value();
} else {
PropMap aPropMap;
- anOnjectMap.insert(theEntry, aPropMap);
- return anOnjectMap.find(theEntry).value();
+ anObjectMap.insert(theEntry, aPropMap);
+ return anObjectMap.find(theEntry).value();
}
} else {
PropMap aPropMap;
ObjMap anObjMap;
anObjMap.insert(theEntry,aPropMap);
myViewMgrMap.insert(theViewMgrId, anObjMap);
- return anObjMap.find(theEntry).value();
+
+ ObjMap& anObjectMap = myViewMgrMap.find(theViewMgrId).value();
+ return anObjectMap.find(theEntry).value();
}
}
return getView(MAIN_VIEW)->backgroundImageFilename();
}
+QImage OCCViewer_ViewFrame::dumpView()
+{
+ foreach (OCCViewer_ViewWindow* aView, myViews) {
+ if (aView->isVisible())
+ return aView->dumpView();
+ }
+ return QImage();
+}
+
+bool OCCViewer_ViewFrame::dumpViewToFormat( const QImage& image, const QString& fileName, const QString& format )
+{
+ foreach (OCCViewer_ViewWindow* aView, myViews) {
+ if (aView->isVisible())
+ return aView->dumpViewToFormat( image, fileName, format );
+ }
+ return false;
+}
+
void OCCViewer_ViewFrame::onContextMenuRequested(QContextMenuEvent*)
{
myPopupRequestedView = dynamic_cast<OCCViewer_ViewWindow*>(sender());
virtual void onDumpView();
+protected:
+ virtual QImage dumpView();
+ virtual bool dumpViewToFormat( const QImage&, const QString&, const QString& );
+
private slots:
void onContextMenuRequested(QContextMenuEvent*);
void Hide( QHideEvent * );
void maximized( OCCViewer_ViewWindow*, bool );
-protected:
+public:
virtual QImage dumpView();
virtual bool dumpViewToFormat( const QImage&, const QString& fileName, const QString& format );
+
+protected:
virtual QString filter() const;
/* Transformation selected but not started yet */
libSalomePy_la_LDFLAGS = $(PYTHON_LIBS) $(QT_MT_LIBS) $(VTK_LIBS) $(OGL_LIBS) \
../LightApp/libLightApp.la \
- -lvtkCommonPythonD -lvtkGraphicsPythonD -lvtkImagingPythonD
+ -lvtkCommonPythonD -lvtkGraphicsPythonD -lvtkImagingPythonD -lvtkPythonCore
if ( window ) {
if ( dynamic_cast<SVTK_ViewWindow*>( window ) )
( dynamic_cast<SVTK_ViewWindow*>( window ) )->onFitAll();
- else if ( dynamic_cast<SOCC_ViewWindow*>( window ) )
- ( dynamic_cast<SOCC_ViewWindow*>( window ) )->onFitAll();
+ else if ( dynamic_cast<OCCViewer_ViewWindow*>( window ) )
+ ( dynamic_cast<OCCViewer_ViewWindow*>( window ) )->onFitAll();
else if ( dynamic_cast<SPlot2d_ViewWindow*>( window ) )
( dynamic_cast<SPlot2d_ViewWindow*>( window ) )->onFitAll();
}
if ( window ) {
if ( dynamic_cast<SVTK_ViewWindow*>( window ) )
(dynamic_cast<SVTK_ViewWindow*>( window ))->onResetView();
- else if ( dynamic_cast<SOCC_ViewWindow*>( window ) )
- (dynamic_cast<SOCC_ViewWindow*>( window ))->onResetView();
+ else if ( dynamic_cast<OCCViewer_ViewWindow*>( window ) )
+ (dynamic_cast<OCCViewer_ViewWindow*>( window ))->onResetView();
else if ( dynamic_cast<SPlot2d_ViewWindow*>( window ) )
(dynamic_cast<SPlot2d_ViewWindow*>( window ))->onFitAll();
// VSR: there is no 'ResetView' functionality for Plot2d viewer,
break;
}
}
- else if ( dynamic_cast<SOCC_ViewWindow*>( window ) ) {
+ else if ( dynamic_cast<OCCViewer_ViewWindow*>( window ) ) {
switch( myView ) {
case __ViewTop:
- (dynamic_cast<SOCC_ViewWindow*>( window ))->onTopView(); break;
+ (dynamic_cast<OCCViewer_ViewWindow*>( window ))->onTopView(); break;
case __ViewBottom:
- (dynamic_cast<SOCC_ViewWindow*>( window ))->onBottomView(); break;
+ (dynamic_cast<OCCViewer_ViewWindow*>( window ))->onBottomView(); break;
case __ViewLeft:
- (dynamic_cast<SOCC_ViewWindow*>( window ))->onLeftView(); break;
+ (dynamic_cast<OCCViewer_ViewWindow*>( window ))->onLeftView(); break;
case __ViewRight:
- (dynamic_cast<SOCC_ViewWindow*>( window ))->onRightView(); break;
+ (dynamic_cast<OCCViewer_ViewWindow*>( window ))->onRightView(); break;
case __ViewFront:
- (dynamic_cast<SOCC_ViewWindow*>( window ))->onFrontView(); break;
+ (dynamic_cast<OCCViewer_ViewWindow*>( window ))->onFrontView(); break;
case __ViewBack:
- (dynamic_cast<SOCC_ViewWindow*>( window ))->onBackView(); break;
+ (dynamic_cast<OCCViewer_ViewWindow*>( window ))->onBackView(); break;
default:
break;
}
: myParent( 0 ),
myOpen( false ),
myCheck( false ),
- myAutoDel( true )
+ myAutoDel( true ),
+ _modified( false )
{
setParent( p );
signal()->emitCreated( this );
// Create Qt application instance;
// this should be done the very first!
SALOME_QApplication _qappl( argc, argv );
- _qappl.setOrganizationName( "SALOME" );
- _qappl.setApplicationName( "SALOME" );
+ _qappl.setOrganizationName( "salome" );
+ _qappl.setApplicationName( "salome" );
_qappl.setApplicationVersion( salomeVersion() );
// Add application library path (to search style plugin etc...)