2 * Scilab ( http://www.scilab.org/ ) - This file is part of Scilab
3 * Copyright (C) 2004-2006 - INRIA - Fabrice Leray
4 * Copyright (C) 2006 - INRIA - Allan Cornet
5 * Copyright (C) 2006 - INRIA - Jean-Baptiste Silvy
6 * Copyright (C) 2010 - DIGITEO - Manuel Juliachs
8 * This file must be used under the terms of the CeCILL.
9 * This source file is licensed as described in the file COPYING, which
10 * you should have received as part of this distribution. The terms
11 * are also available at
12 * http://www.cecill.info/licences/Licence_CeCILL_V2.1-en.txt
16 /*------------------------------------------------------------------------*/
17 /* file: set_tight_limits_property.c */
18 /* desc : function to modify in Scilab the tight_limits field of */
20 /*------------------------------------------------------------------------*/
22 #include "setHandleProperty.h"
23 #include "SetProperty.h"
24 #include "getPropertyAssignedValue.h"
25 #include "SetPropertyStatus.h"
27 #include "localization.h"
29 #include "setGraphicObjectProperty.h"
30 #include "graphicObjectProperties.h"
32 /*------------------------------------------------------------------------*/
33 int set_tight_limits_property(void* _pvCtx, int iObjUID, void* _pvData, int valueType, int nbRow, int nbCol)
39 b = tryGetBooleanValueFromStack(_pvData, valueType, nbRow, nbCol, "tight_limits");
40 if (b == NOT_A_BOOLEAN_VALUE)
42 return SET_PROPERTY_ERROR;
45 status = setGraphicObjectProperty(iObjUID, __GO_TIGHT_LIMITS__, &b, jni_bool, 1);
49 return SET_PROPERTY_SUCCEED;
53 Scierror(999, _("'%s' property does not exist for this handle.\n"), "tight_limits");
54 return SET_PROPERTY_ERROR;
57 /*------------------------------------------------------------------------*/