#include "machine.h"Include dependency graph for getPropertyAssignedValue.h:

This graph shows which files directly or indirectly include this file:

Go to the source code of this file.
copy a double vector from the scilab stack
Definition at line 47 of file getPropertyAssignedValue.c.
References doubleArrayCopy(), and getDoubleMatrixFromStack().
Referenced by createCopyDoubleVectorFromStack(), set_axes_bounds_property(), set_data_bounds_property(), set_margins_property(), set_surface_color_property(), and set_triangles_property().
00048 { 00049 doubleArrayCopy( dest, getDoubleMatrixFromStack( stackPointer ), nbElement ) ; 00050 }
Here is the call graph for this function:

Here is the caller graph for this function:

copy a double vector from the scilab stack to an int array with int cast for each parameter.
Definition at line 52 of file getPropertyAssignedValue.c.
References getDoubleMatrixFromStack(), and i.
Referenced by set_interp_color_vector_property(), and set_segs_color_property().
00053 { 00054 int i ; 00055 double * values = getDoubleMatrixFromStack( stackPointer ) ; 00056 for ( i = 0 ; i < nbElement ; i++ ) 00057 { 00058 dest[i] = (int) values[i] ; 00059 } 00060 }
Here is the call graph for this function:

Here is the caller graph for this function:

| AssignedList* createAssignedList | ( | int | paramNum, | |
| int | nbElement | |||
| ) |
create a new instance of an object used to retrieve fields of a tlist stored on the stack
| paramNum | rank of the list within the Rhs parameters | |
| nbElement | number of element in the list |
Definition at line 149 of file getPropertyAssignedValue.c.
References AssignedList::curElement, GetRhsVar, MALLOC, AssignedList::nbElement, NULL, AssignedList::paramNumber, sciprint(), and AssignedList::stackPointer.
Referenced by createTlistForTicks(), and set_data_property().
00150 { 00151 AssignedList * newList = NULL ; 00152 int nbRow = 0 ; 00153 int nbCol = 0 ; 00154 00155 newList = MALLOC( sizeof(AssignedList) ) ; 00156 00157 if ( newList == NULL ) 00158 { 00159 return NULL ; 00160 } 00161 00162 newList->nbElement = nbElement + 1 ; 00163 newList->curElement = 2 ; /* begin with 1 and 1 are the names */ 00164 newList->paramNumber = paramNum ; 00165 00166 /* get the stack pointer */ 00167 GetRhsVar( paramNum, "t", &nbRow, &nbCol, &(newList->stackPointer) ) ; 00168 00169 /* check the size */ 00170 if ( nbRow != newList->nbElement || nbCol != 1 ) 00171 { 00172 sciprint( "Wrong size for tlist.\n" ) ; 00173 return NULL ; 00174 } 00175 return newList ; 00176 }
Here is the call graph for this function:

Here is the caller graph for this function:

| double* createCopyDoubleMatrixFromList | ( | AssignedList * | list, | |
| int * | nbRow, | |||
| int * | nbCol | |||
| ) |
create a copy of the current matrix in the tlist
| in/out] | list object used to retrieve elements | |
| [out] | nbRow | number of row of the returned matrix or -1 if an error occurred |
| [out] | nbCol | number of column of the returned matrix or -1 if an error occurred |
Definition at line 272 of file getPropertyAssignedValue.c.
References doubleArrayCopy(), getCurrentDoubleMatrixFromList(), MALLOC, and NULL.
Referenced by set3ddata(), set_x_ticks_property(), set_y_ticks_property(), set_z_ticks_property(), setchampdata(), and setgrayplotdata().
00273 { 00274 /* get the matrix */ 00275 double * stackValues = getCurrentDoubleMatrixFromList( list, nbRow, nbCol ) ; 00276 int nbElement = (*nbRow) * (*nbCol) ; 00277 00278 double * copyMatrix = NULL ; 00279 00280 if ( nbElement == 0 ) 00281 { 00282 return NULL ; 00283 } 00284 00285 /* copy */ 00286 00287 copyMatrix = MALLOC( (*nbRow) * (*nbCol) * sizeof( double ) ) ; 00288 00289 if ( copyMatrix == NULL ) 00290 { 00291 *nbRow = -1 ; 00292 *nbCol = -1 ; 00293 return NULL ; 00294 } 00295 00296 doubleArrayCopy( copyMatrix, stackValues, nbElement ) ; 00297 00298 return copyMatrix ; 00299 00300 }
Here is the call graph for this function:

Here is the caller graph for this function:

create a copy of a vector (or Matrix) of double stored in the stack
Definition at line 62 of file getPropertyAssignedValue.c.
References copyDoubleVectorFromStack(), MALLOC, NULL, and res.
Referenced by set_triangles_property(), set_x_shift_property(), set_xtics_coord_property(), set_y_shift_property(), set_ytics_coord_property(), and set_z_shift_property().
00063 { 00064 double * res = MALLOC( nbElement * sizeof(double) ) ; 00065 if ( res == NULL ) 00066 { 00067 return NULL ; 00068 } 00069 copyDoubleVectorFromStack( stackPointer, res, nbElement ) ; 00070 return res ; 00071 }
Here is the call graph for this function:

Here is the caller graph for this function:

| char** createCopyStringMatrixFromList | ( | AssignedList * | list, | |
| int * | nbRow, | |||
| int * | nbCol | |||
| ) |
create a copy of the current matrix in the tlist
| in/out] | list object used to retrieve elements | |
| [out] | nbRow | number of row of the returned matrix |
| [out] | nbCol | number of column of the returned matrix |
Definition at line 302 of file getPropertyAssignedValue.c.
References createStringArrayCopy(), getCurrentStringMatrixFromList(), and NULL.
Referenced by set_x_ticks_property(), set_y_ticks_property(), and set_z_ticks_property().
00303 { 00304 /* get the matrix */ 00305 char ** stackValues = getCurrentStringMatrixFromList( list, nbRow, nbCol ) ; 00306 int nbElement = (*nbRow) * (*nbCol) ; 00307 00308 if ( nbElement == 0 ) 00309 { 00310 return NULL ; 00311 } 00312 00313 return createStringArrayCopy( stackValues, nbElement ) ; 00314 }
Here is the call graph for this function:

Here is the caller graph for this function:

create a copy of a stringMatrix which is in the stack
Definition at line 84 of file getPropertyAssignedValue.c.
References FREE, getStringMatrixFromStack(), i, j, MALLOC, NULL, res, and size.
Referenced by set_tics_labels_property().
00085 { 00086 int i ; 00087 char ** res = MALLOC( nbElement * sizeof(char *) ) ; 00088 char ** values = getStringMatrixFromStack( stackPointer ) ; 00089 00090 if ( res == NULL ) 00091 { 00092 return NULL ; 00093 } 00094 00095 for ( i = 0 ; i < nbElement ; i++ ) 00096 { 00097 int size = strlen( values[i] ) + 1 ; 00098 res[i] = MALLOC( size * sizeof(char) ) ; 00099 00100 if ( res[i] == NULL ) 00101 { 00102 /* deallocate what have been allocated */ 00103 int j ; 00104 for ( j = 0 ; j < i ; j++ ) 00105 { 00106 FREE( res[j] ) ; 00107 } 00108 FREE( res ) ; 00109 return NULL ; 00110 } 00111 00112 strcpy( res[i], values[i] ) ; 00113 } 00114 00115 return res ; 00116 00117 }
Here is the call graph for this function:

Here is the caller graph for this function:

| void destroyAssignedList | ( | AssignedList * | list | ) |
destroy the object used to glance through a tlist
Definition at line 178 of file getPropertyAssignedValue.c.
References FREE.
Referenced by set_data_property(), set_x_ticks_property(), set_y_ticks_property(), and set_z_ticks_property().
00179 { 00180 FREE( list ) ; 00181 }
Here is the caller graph for this function:

| int getAssignedListNbElement | ( | AssignedList * | list | ) |
return the number of element of a tlist
Definition at line 183 of file getPropertyAssignedValue.c.
References AssignedList::nbElement.
Referenced by set3ddata().
00184 { 00185 return list->nbElement - 1 ; 00186 }
Here is the caller graph for this function:

| double* getCurrentDoubleMatrixFromList | ( | AssignedList * | list, | |
| int * | nbRow, | |||
| int * | nbCol | |||
| ) |
retrieve the current property of a tlist and move to the next
| in/out] | list object used to retrieve elements | |
| [out] | nbRow | number of row of the returned matrix |
| [out] | nbCol | number of column of the returned matrix |
Definition at line 241 of file getPropertyAssignedValue.c.
References AssignedList::curElement, getDoubleMatrixFromList(), AssignedList::nbElement, NULL, and res.
Referenced by createCopyDoubleMatrixFromList(), createTlistForTicks(), and set3ddata().
00242 { 00243 double * res = NULL ; 00244 if ( list->curElement > list->nbElement ) 00245 { 00246 *nbRow = 0 ; 00247 *nbCol = 0 ; 00248 return NULL ; 00249 } 00250 00251 res = getDoubleMatrixFromList( list, list->curElement, nbRow, nbCol ) ; 00252 list->curElement++ ; 00253 return res ; 00254 }
Here is the call graph for this function:

Here is the caller graph for this function:

| char** getCurrentStringMatrixFromList | ( | AssignedList * | list, | |
| int * | nbRow, | |||
| int * | nbCol | |||
| ) |
retrieve the current property of a tlist and move to the next
| in/out] | list object used to retrieve elements | |
| [out] | nbRow | number of row of the returned matrix |
| [out] | nbCol | number of column of the returned matrix |
Definition at line 256 of file getPropertyAssignedValue.c.
References AssignedList::curElement, getStringMatrixFromList(), AssignedList::nbElement, NULL, and res.
Referenced by createCopyStringMatrixFromList(), and createTlistForTicks().
00257 { 00258 char ** res = NULL ; 00259 if ( list->curElement > list->nbElement ) 00260 { 00261 *nbRow = 0 ; 00262 *nbCol = 0 ; 00263 return NULL ; 00264 } 00265 00266 res = getStringMatrixFromList( list, list->curElement, nbRow, nbCol ) ; 00267 list->curElement++ ; 00268 return res ; 00269 00270 }
Here is the call graph for this function:

Here is the caller graph for this function:

| double getDoubleFromStack | ( | int | stackPointer | ) |
retrieve a single double from the stack
Definition at line 37 of file getPropertyAssignedValue.c.
References stk.
Referenced by sci_show_window(), set_arrow_size_factor_property(), set_arrow_size_property(), set_background_property(), set_bar_width_property(), set_callbackmevent_property(), set_color_flag_property(), set_color_mode_property(), set_current_figure_property(), set_default_values_property(), set_figure_id_property(), set_font_angle_property(), set_font_color_property(), set_font_foreground_property(), set_font_size_property(), set_font_style_property(), set_foreground_property(), set_hidden_axis_color_property(), set_hidden_color_property(), set_labels_font_color_property(), set_labels_font_size_property(), set_labels_font_style_property(), set_line_style_property(), set_mark_background_property(), set_mark_foreground_property(), set_mark_size_property(), set_mark_style_property(), set_polyline_style_property(), set_position_property(), set_segs_color_property(), set_sub_tics_property(), set_thickness_property(), and set_tics_color_property().
00038 { 00039 return *(stk( stackPointer )); 00040 }
Here is the caller graph for this function:

| double* getDoubleMatrixFromList | ( | AssignedList * | list, | |
| int | rank, | |||
| int * | nbRow, | |||
| int * | nbCol | |||
| ) |
retrieve a field of a tlist
| [in] | list | object used to retrieve elements |
| rank | position of the element in the list ( first, second, ...) Note that is it not possible to get the properties names with this function | |
| [out] | nbRow | number of row of the returned matrix |
| [out] | nbCol | number of column of the returned matrix |
Definition at line 225 of file getPropertyAssignedValue.c.
References getDoubleMatrixFromStack(), GetListRhsVar, and AssignedList::paramNumber.
Referenced by getCurrentDoubleMatrixFromList(), and isListCurrentElementEmptyMatrix().
00226 { 00227 int valueStackPointer = 0 ; 00228 GetListRhsVar( list->paramNumber, rank, "d", nbRow, nbCol, &valueStackPointer ) ; 00229 00230 return getDoubleMatrixFromStack( valueStackPointer ) ; 00231 }
Here is the call graph for this function:

Here is the caller graph for this function:

| double* getDoubleMatrixFromStack | ( | int | stackPointer | ) |
retrieve a double matrix from the scilab stack
Definition at line 42 of file getPropertyAssignedValue.c.
References stk.
Referenced by copyDoubleVectorFromStack(), copyDoubleVectorToIntFromStack(), getdDataBoundsFromStack(), getDoubleMatrixFromList(), set_axes_size_property(), set_clip_box_property(), set_color_map_property(), set_data_property(), set_figure_position_property(), set_figure_size_property(), set_grid_property(), set_interp_color_vector_property(), set_position_property(), set_rotation_angles_property(), set_sub_tics_property(), set_text_box_property(), set_viewport_property(), set_z_bounds_property(), and set_zoom_box_property().
00043 { 00044 return stk( stackPointer ) ; 00045 }
Here is the caller graph for this function:

retireve a string on from the scilab stack
Definition at line 119 of file getPropertyAssignedValue.c.
References hstk.
Referenced by sci_show_window(), set_current_axes_property(), set_current_entity_property(), and set_current_figure_property().
00120 { 00121 return (unsigned long) *(hstk( stackPointer )) ; 00122 }
Here is the caller graph for this function:

get the number of element of a tlist stored in the rhs
| paramNum | rank of the list within the Rhs parameters |
Definition at line 137 of file getPropertyAssignedValue.c.
References GetRhsVar.
Referenced by set_data_property().
00138 { 00139 int nbRow = 0 ; 00140 int nbCol = 0 ; 00141 int stackPointer = 0 ; 00142 00143 GetRhsVar( paramNum, "t", &nbRow, &nbCol, &stackPointer ) ; 00144 00145 return nbRow - 1 ; 00146 00147 }
Here is the caller graph for this function:

| char* getStringFromStack | ( | int | stackPointer | ) |
retrieve a string on from the scilab stack
Definition at line 73 of file getPropertyAssignedValue.c.
References cstk.
Referenced by isStringParamEqual(), set_callback_property(), set_data_mapping_property(), set_figure_name_property(), set_font_name_property(), set_format_n_property(), set_info_message_property(), set_log_flags_property(), set_old_style_property(), set_pixel_drawing_mode_property(), set_rotation_style_property(), set_tics_style_property(), and set_visible_property().
00074 { 00075 return cstk( stackPointer ) ; 00076 }
Here is the caller graph for this function:

| char** getStringMatrixFromList | ( | AssignedList * | list, | |
| int | rank, | |||
| int * | nbRow, | |||
| int * | nbCol | |||
| ) |
retrieve a field of a tlist
| [in] | list | object used to retrieve elements |
| rank | position of the element in the list ( first, second, ...) Note that is it not possible to get the properties names with this function | |
| [out] | nbRow | number of row of the returned matrix |
| [out] | nbCol | number of column of the returned matrix |
Definition at line 233 of file getPropertyAssignedValue.c.
References GetListRhsVar, getStringMatrixFromStack(), and AssignedList::paramNumber.
Referenced by getCurrentStringMatrixFromList().
00234 { 00235 int valueStackPointer = 0 ; 00236 GetListRhsVar( list->paramNumber, rank, "S", nbRow, nbCol, &valueStackPointer ) ; 00237 00238 return getStringMatrixFromStack( valueStackPointer ) ; 00239 }
Here is the call graph for this function:

Here is the caller graph for this function:

| char** getStringMatrixFromStack | ( | int | stackPointer | ) |
retrieve a string matrix on from the scilab stack
Definition at line 78 of file getPropertyAssignedValue.c.
Referenced by createCopyStringMatrixFromStack(), getStringMatrixFromList(), set_auto_ticks_property(), set_axes_reverse_property(), set_axes_visible_property(), and set_text_property().
00079 { 00080 /* strange but it was taken from sci_set */ 00081 return (char **) stackPointer ; 00082 }
Here is the caller graph for this function:

| BOOL isListCurrentElementDoubleMatrix | ( | AssignedList * | list | ) |
Return whether the current element of the list is a double matrix or not.
Definition at line 193 of file getPropertyAssignedValue.c.
References AssignedList::curElement, ElementType, and AssignedList::paramNumber.
Referenced by createTlistForTicks(), and isListCurrentElementEmptyMatrix().
00194 { 00195 return ( ElementType( list->paramNumber, list->curElement ) == 1 ) ; 00196 }
Here is the caller graph for this function:

| BOOL isListCurrentElementEmptyMatrix | ( | AssignedList * | list | ) |
Return whether the current element of the list is an empty matrix or not.
Definition at line 203 of file getPropertyAssignedValue.c.
References AssignedList::curElement, FALSE, getDoubleMatrixFromList(), isListCurrentElementDoubleMatrix(), and TRUE.
Referenced by createTlistForTicks().
00204 { 00205 int nbRow = 0 ; 00206 int nbCol = 0 ; 00207 00208 if ( !isListCurrentElementDoubleMatrix( list ) ) 00209 { 00210 /* empty matrix is a double matrix */ 00211 return FALSE ; 00212 } 00213 00214 getDoubleMatrixFromList( list, list->curElement, &nbRow, &nbCol ) ; 00215 00216 if ( nbRow * nbCol == 0 ) 00217 { 00218 return TRUE ; 00219 } 00220 00221 return FALSE ; 00222 00223 }
Here is the call graph for this function:

Here is the caller graph for this function:

| BOOL isListCurrentElementStringMatrix | ( | AssignedList * | list | ) |
Return whether the current element of the list is a string matrix or not.
Definition at line 198 of file getPropertyAssignedValue.c.
References AssignedList::curElement, ElementType, and AssignedList::paramNumber.
Referenced by createTlistForTicks().
00199 { 00200 return ( ElementType( list->paramNumber, list->curElement ) == 10 ) ; 00201 }
Here is the caller graph for this function:

| BOOL isParameterDoubleMatrix | ( | int | type | ) |
return if a stack parameter is a Handle
| type | type of the parameter |
Definition at line 22 of file getPropertyAssignedValue.c.
Referenced by sci_show_window(), set_arrow_size_factor_property(), set_arrow_size_property(), set_axes_bounds_property(), set_axes_size_property(), set_background_property(), set_bar_width_property(), set_callbackmevent_property(), set_clip_box_property(), set_color_flag_property(), set_color_map_property(), set_color_mode_property(), set_current_figure_property(), set_data_bounds_property(), set_data_property(), set_default_values_property(), set_figure_id_property(), set_figure_position_property(), set_figure_size_property(), set_font_angle_property(), set_font_color_property(), set_font_foreground_property(), set_font_size_property(), set_font_style_property(), set_foreground_property(), set_grid_property(), set_hidden_axis_color_property(), set_hidden_color_property(), set_interp_color_vector_property(), set_labels_font_color_property(), set_labels_font_size_property(), set_labels_font_style_property(), set_line_style_property(), set_margins_property(), set_mark_background_property(), set_mark_foreground_property(), set_mark_size_property(), set_mark_style_property(), set_polyline_style_property(), set_position_property(), set_rotation_angles_property(), set_segs_color_property(), set_sub_tics_property(), set_surface_color_property(), set_text_box_property(), set_thickness_property(), set_tics_color_property(), set_triangles_property(), set_viewport_property(), set_x_shift_property(), set_xtics_coord_property(), set_y_shift_property(), set_z_bounds_property(), set_z_shift_property(), set_zoom_box_property(), and set_zoom_state_property().
00023 { 00024 return ( type == 1 ) ; 00025 }
Here is the caller graph for this function:

| BOOL isParameterHandle | ( | int | type | ) |
return if a stack parameter is a Handle
| type | type of the parameter |
Definition at line 17 of file getPropertyAssignedValue.c.
Referenced by sci_show_window(), set_current_axes_property(), set_current_entity_property(), and set_current_figure_property().
00018 { 00019 return ( type == 9 ) ; 00020 }
Here is the caller graph for this function:

| BOOL isParameterStringMatrix | ( | int | type | ) |
return if a stack parameter is a string matrix
| type | type of the parameter |
Definition at line 32 of file getPropertyAssignedValue.c.
Referenced by set_alignment_property(), set_auto_clear_property(), set_auto_dimensionning_property(), set_auto_position_property(), set_auto_resize_property(), set_auto_rotation_property(), set_auto_scale_property(), set_auto_ticks_property(), set_axes_reverse_property(), set_axes_visible_property(), set_bar_layout_property(), set_box_property(), set_callback_property(), set_callback_type_property(), set_cdata_mapping_property(), set_clip_state_property(), set_closed_property(), set_colored_property(), set_cube_scaling_property(), set_data_mapping_property(), set_figure_name_property(), set_figure_style_property(), set_fill_mode_property(), set_font_name_property(), set_format_n_property(), set_handle_visible_property(), set_immediate_drawing_property(), set_info_message_property(), set_interp_color_mode_property(), set_isoview_property(), set_line_mode_property(), set_log_flags_property(), set_mark_mode_property(), set_mark_size_unit_property(), set_menu_enable_property(), set_old_style_property(), set_pixel_drawing_mode_property(), set_rotation_style_property(), set_surface_mode_property(), set_text_box_mode_property(), set_text_property(), set_tics_direction_property(), set_tics_labels_property(), set_tics_segment_property(), set_tics_style_property(), set_tight_limits_property(), set_view_property(), set_visible_property(), set_x_location_property(), and set_y_location_property().
00033 { 00034 return ( type == 10 ) ; 00035 }
Here is the caller graph for this function:

| BOOL isParameterTlist | ( | int | type | ) |
return if a stack parameter is a tlist
| type | type of the parameter |
Definition at line 27 of file getPropertyAssignedValue.c.
Referenced by set_data_property(), set_x_ticks_property(), set_y_ticks_property(), and set_z_ticks_property().
00028 { 00029 return ( type == 16 ) ; 00030 }
Here is the caller graph for this function:

| BOOL isStringParamEqual | ( | int | stackPointer, | |
| const char * | str | |||
| ) |
compare the string stored in the stack with str
Definition at line 124 of file getPropertyAssignedValue.c.
References FALSE, getStringFromStack(), and TRUE.
Referenced by set_alignment_property(), set_auto_clear_property(), set_auto_dimensionning_property(), set_auto_position_property(), set_auto_resize_property(), set_auto_rotation_property(), set_auto_scale_property(), set_bar_layout_property(), set_box_property(), set_callback_type_property(), set_cdata_mapping_property(), set_clip_state_property(), set_closed_property(), set_colored_property(), set_cube_scaling_property(), set_data_mapping_property(), set_figure_style_property(), set_fill_mode_property(), set_handle_visible_property(), set_immediate_drawing_property(), set_interp_color_mode_property(), set_isoview_property(), set_line_mode_property(), set_mark_mode_property(), set_mark_size_unit_property(), set_menu_enable_property(), set_old_style_property(), set_pixmap_property(), set_rotation_style_property(), set_surface_mode_property(), set_text_box_mode_property(), set_tics_direction_property(), set_tics_segment_property(), set_tics_style_property(), set_tight_limits_property(), set_view_property(), set_visible_property(), set_x_location_property(), set_y_location_property(), and set_zoom_state_property().
00125 { 00126 if ( strcmp( getStringFromStack( stackPointer ), str ) == 0 ) 00127 { 00128 return TRUE ; 00129 } 00130 else 00131 { 00132 return FALSE ; 00133 } 00134 }
Here is the call graph for this function:

Here is the caller graph for this function:

| void rewindAssignedList | ( | AssignedList * | list | ) |
set the current element to the first
Definition at line 188 of file getPropertyAssignedValue.c.
References AssignedList::curElement.
Referenced by createTlistForTicks(), and set3ddata().
00189 { 00190 list->curElement = 2 ; 00191 }
Here is the caller graph for this function:

1.5.1