() |
#
# Purpose : This file provides an example of a call to the
# function xy_curve_delete()
#
# This session file opens a new database ’new.db’
# A new xy window and a xy curve is created. The
# above mentioned function is then called to
# delete the curve from the xy window.
#
# This file can be run by starting a session of
# Patran, opening a new or existing database,
# and running this session file through the
# "File","Session","Play" pulldown menus
# on the menu bar.
#
# The function xy_curve_delete()
# has the following arguments:
#
# xy_curve_delete
# ( curve_name )
#
#---------------------------------------------------------------------
# Variable Declarations
STRING s_curve_name[32]
STRING s_window_name[32]
INTEGER i_return_value
REAL r_x_location
REAL r_y_location
REAL r_width
REAL r_height
#---------------------------------------------------------------------
# Opening new database new.db
uil_file_new.go("","new.db")
$? YES 36000002
# Create a new window.
s_window_name = "XY_Window"
r_x_location = 2.5
r_y_location = 3.5
r_width = 5.0
r_height = 5.0
i_return_value = @
xy_window_create @
( s_window_name, @
r_x_location, @
r_y_location, @
r_width, @
r_height )
dump i_return_value
#---------------------------------------------------------------------
# Create a curve
i_return_value = @
xy_curve_create("curve_1", "data of x vs y", 1)
dump i_return_value
i_return_value = @
xy_curve_data_set @
( "curve_1", FALSE, 10, [1., 2., 3., 4., @
5., 6., 7., 8., 9., 10.], [-5., 6., 4., @
-10., -7., 10., 15., 23., -20., -11.])
dump i_return_value
#---------------------------------------------------------------------
# Session file paused. Press "Resume" to continue
sf_pause()
#---------------------------------------------------------------------
# Delete the curve
s_curve_name = "curve_1"
i_return_value = @
xy_curve_delete @
( s_curve_name )
dump i_return_value
#---------------------------------------------------------------------
() |
#
# Purpose : This file provides an example of a call to the
# function xy_title_delete()
#
# This session file opens a database ’new.db’
# and creates a new xy window. A title is
# created and posted to the window. The above
# mentioned function is then called to delete the
# title.
#
# This file can be run by starting a session of
# Patran, opening a new or existing database,
# and running this session file through the
# "File","Session","Play" pulldown menus
# on the menu bar.
#
# The function xy_title_delete()
# has the following arguments:
#
# xy_title_delete
# ( title_name )
#
#---------------------------------------------------------------------
# Variable Declarations
STRING s_title_name[256]
STRING s_window_name[32]
INTEGER i_return_value
REAL r_x_location
REAL r_y_location
REAL r_width
REAL r_height
#---------------------------------------------------------------------
# Opening new database new.db
uil_file_new.go("","new.db")
$? YES 36000002
# Create a new window.
s_window_name = "XY_Window"
r_x_location = 2.5
r_y_location = 3.5
r_width = 5.0
r_height = 5.0
i_return_value = @
xy_window_create @
( s_window_name, @
r_x_location, @
r_y_location, @
r_width, @
r_height )
dump i_return_value
#---------------------------------------------------------------------
# Create a title
i_return_value = @
xy_title_create @
( "TITLE_1", "TITLE_1", 14, [5.0, 10.0], 1)
dump i_return_value
#---------------------------------------------------------------------
# Session file paused. Press "Resume" to continue..
sf_pause()
#---------------------------------------------------------------------
# Delete the title
s_title_name = "TITLE_1"
i_return_value = @
xy_title_delete @
( s_title_name)
dump i_return_value
#---------------------------------------------------------------------