() |
## Purpose : This file provides an example of a call to the# function xy_curve_create()## This file opens a new database "new.db" and# counts the number of curves in the xy plot.# Later it creates a curve and gets the count# of curves again.## This file can be run by starting a session of# Patran, and running this session file # through the "File","Session","Play" pulldown # menus on the menu bar.## The function xy_curve_create()# has the following arguments:## xy_curve_create# ( curve_name,# text,# text_color )##---------------------------------------------------------------------# Variable DeclarationsSTRING s_curve_name[32]STRING s_text[32]INTEGER i_text_colorINTEGER i_ncurvesSTRING s_window_name[32]REAL r_x_locationREAL r_y_locationREAL r_widthREAL r_heightINTEGER i_return_value#---------------------------------------------------------------------# Open a new database "new.db"uil_file_new.go("","new.db")$? YES 36000002# Create a xy window.s_window_name = "XY_Window"r_x_location = 2.5r_y_location = 3.5r_width = 5.0r_height = 5.0i_return_value = @ xy_window_create @ ( s_window_name, @ r_x_location, @ r_y_location, @ r_width, @ r_height )dump i_return_value# Get the number of curves.i_return_value = @ xy_curve_num_get @ ( i_ncurves )dump i_return_valuedump i_ncurves# Session file paused. Press "Resume" to continue.sf_pause()# Create a curve.s_curve_name = "new_curve"s_text = "new_curve"i_text_color = 1i_return_value = @ xy_curve_create @ ( s_curve_name, @ s_text, @ i_text_color )dump i_return_value# Assign data points to the curvei_return_value = @ xy_curve_data_set @ ( s_curve_name, FALSE, 5, @ [1., 3., 6., 8., 9.], @ [2., 8., 4., 9., 5.] )dump i_return_value# Get the number of curves.i_return_value = @ xy_curve_num_get @ ( i_ncurves )dump i_return_valuedump i_ncurves#---------------------------------------------------------------------() |
## Purpose : This file provides an example of two calls# to the function xy_curve_current_get()## This file opens a new database "new.db" and# creates a window and two curves. Later it# assigns data points to the curves. It then sets# the current curve and gets it. Finally it sets# and gets the current curve again.## This file can be run by starting a session of# Patran, and running this session file # through the "File","Session","Play" pulldown # menus on the menu bar.## The function xy_curve_current_get()# has the following arguments:## xy_curve_current_get# ( curve_name )##---------------------------------------------------------------------# Variable DeclarationsSTRING s_curve_name[32]STRING s_text[32]INTEGER i_text_colorSTRING s_window_name[32]REAL r_x_locationREAL r_y_locationREAL r_widthREAL r_heightSTRING s_curve_name[32]INTEGER i_return_value#---------------------------------------------------------------------# Open a new database "new.db"uil_file_new.go("","new.db")$? YES 36000002# Create a xy window.s_window_name = "XY_Window"r_x_location = 2.5r_y_location = 3.5r_width = 5.0r_height = 5.0i_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.s_curve_name = "curve_1"s_text = "temperature"i_text_color = 1i_return_value = @ xy_curve_create @ ( s_curve_name, @ s_text, @ i_text_color )dump i_return_value# Assign data points to the curvei_return_value = @ xy_curve_data_set @ ( s_curve_name, FALSE, 5, @ [1., 3., 6., 8., 9.], @ [2., 8., 4., 9., 5.] )dump i_return_value# Create a curve.s_curve_name = "curve_2"s_text = "viscosity"i_text_color = 2i_return_value = @ xy_curve_create @ ( s_curve_name, @ s_text, @ i_text_color )dump i_return_value# Assign data points to the curvei_return_value = @ xy_curve_data_set @ ( s_curve_name, FALSE, 5, @ [1., 3., 6., 8., 9.], @ [8., 2., 3., 1., 4.] )dump i_return_value# Set the current curve.s_curve_name = "curve_1"i_return_value = @ xy_curve_current_set @ ( s_curve_name )dump i_return_value# Get the current curve.s_curve_name = ""i_return_value = @ xy_curve_current_get @ ( s_curve_name )dump i_return_valuedump s_curve_name# Session file paused. Press "Resume" to continue.sf_pause()# Set the current curve.s_curve_name = "curve_2"i_return_value = @ xy_curve_current_set @ ( s_curve_name )dump i_return_value# Get the current curve.s_curve_name = ""i_return_value = @ xy_curve_current_get @ ( s_curve_name )dump i_return_valuedump s_curve_name#---------------------------------------------------------------------() |
## Purpose : This file provides an example of two calls# to the function xy_curve_current_set()## This file opens a new database "new.db" and# creates a window and two curves. Later it# assigns data points to the curves. It then sets# the current curve and gets it. Finally it sets# and gets the current curve again.## This file can be run by starting a session of# Patran, and running this session file # through the "File","Session","Play" pulldown # menus on the menu bar.## The function xy_curve_current_set()# has the following arguments:## xy_curve_current_set# ( curve_name )##---------------------------------------------------------------------# Variable DeclarationsSTRING s_curve_name[32]STRING s_text[32]INTEGER i_text_colorSTRING s_window_name[32]REAL r_x_locationREAL r_y_locationREAL r_widthREAL r_heightSTRING s_curve_name[32]INTEGER i_return_value#---------------------------------------------------------------------# Open a new database "new.db"uil_file_new.go("","new.db")$? YES 36000002# Create a xy window.s_window_name = "XY_Window"r_x_location = 2.5r_y_location = 3.5r_width = 5.0r_height = 5.0i_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.s_curve_name = "curve_1"s_text = "temperature"i_text_color = 1i_return_value = @ xy_curve_create @ ( s_curve_name, @ s_text, @ i_text_color )dump i_return_value# Assign data points to the curvei_return_value = @ xy_curve_data_set @ ( s_curve_name, FALSE, 5, @ [1., 3., 6., 8., 9.], @ [2., 8., 4., 9., 5.] )dump i_return_value# Create a curve.s_curve_name = "curve_2"s_text = "viscosity"i_text_color = 2i_return_value = @ xy_curve_create @ ( s_curve_name, @ s_text, @ i_text_color )dump i_return_value# Assign data points to the curvei_return_value = @ xy_curve_data_set @ ( s_curve_name, FALSE, 5, @ [1., 3., 6., 8., 9.], @ [8., 2., 3., 1., 4.] )dump i_return_value# Set the current curve.s_curve_name = "curve_1"i_return_value = @ xy_curve_current_set @ ( s_curve_name )dump i_return_value# Get the current curve.s_curve_name = ""i_return_value = @ xy_curve_current_get @ ( s_curve_name )dump i_return_valuedump s_curve_name# Session file paused. Press "Resume" to continue.sf_pause()# Set the current curve.s_curve_name = "curve_2"i_return_value = @ xy_curve_current_set @ ( s_curve_name )dump i_return_value# Get the current curve.s_curve_name = ""i_return_value = @ xy_curve_current_get @ ( s_curve_name )dump i_return_valuedump s_curve_name#---------------------------------------------------------------------() |
## Purpose : This file provides an example of a call to the# function xy_curve_data_file_get()## This file opens a new database "new.db" and# creates a window and a curve. Later it reads# the data for the curve from a file.## This file can be run by starting a session of# Patran, and running this session file # through the "File","Session","Play" pulldown # menus on the menu bar. The file "curve.xyd"# should be present in the working directory.## The function xy_curve_data_file_get()# has the following arguments:## xy_curve_data_file_get# ( file_name,# curve_name,# set_number )##---------------------------------------------------------------------# Variable DeclarationsSTRING s_text[32]INTEGER i_text_colorSTRING s_window_name[32]REAL r_x_locationREAL r_y_locationREAL r_widthREAL r_heightSTRING s_file_name[32]STRING s_curve_name[32]INTEGER i_set_numberINTEGER i_return_value#---------------------------------------------------------------------# Open a new database "new.db"uil_file_new.go("","new.db")$? YES 36000002# Create a xy window.s_window_name = "XY_Window"r_x_location = 2.5r_y_location = 3.5r_width = 5.0r_height = 5.0i_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.s_curve_name = "curve_1"s_text = "temperature_curve"i_text_color = 1i_return_value = @ xy_curve_create @ ( s_curve_name, @ s_text, @ i_text_color )dump i_return_value# Get the curve data from the file "curve.xyd"s_file_name = "curve.xyd"s_curve_name = "curve_1"i_set_number = 1i_return_value = @ xy_curve_data_file_get @ ( s_file_name, @ s_curve_name, @ i_set_number )dump i_return_value#---------------------------------------------------------------------() |
## Purpose : This file provides an example of a call to the# function xy_curve_data_get()## This file opens a new database "new.db" and# creates a window and a curve. Later it reads# the data for the curve from a file. Finally# it gets the curve data.## This file can be run by starting a session of# Patran, and running this session file # through the "File","Session","Play" pulldown # menus on the menu bar. The file "curve.xyd"# should be present in the working directory.## The function xy_curve_data_get()# has the following arguments:## xy_curve_data_get# ( curve_name,# yonly,# npoints,# x_array,# y_array )##---------------------------------------------------------------------# Variable DeclarationsLOGICAL l_yonlyINTEGER i_npointsREAL ra_x_array(VIRTUAL) REAL ra_y_array(VIRTUAL)STRING s_text[32]INTEGER i_text_colorSTRING s_window_name[32]REAL r_x_locationREAL r_y_locationREAL r_widthREAL r_heightSTRING s_file_name[32]STRING s_curve_name[32]INTEGER i_set_numberINTEGER i_return_value#---------------------------------------------------------------------# Open a new database "new.db"uil_file_new.go("","new.db")$? YES 36000002# Create a xy window.s_window_name = "XY_Window"r_x_location = 2.5r_y_location = 3.5r_width = 5.0r_height = 5.0i_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.s_curve_name = "curve_1"s_text = "temperature"i_text_color = 1i_return_value = @ xy_curve_create @ ( s_curve_name, @ s_text, @ i_text_color )dump i_return_value# Assign data to the curve from file "curve.xyd"s_file_name = "curve.xyd"s_curve_name = "curve_1"i_set_number = 1i_return_value = @ xy_curve_data_file_get @ ( s_file_name, @ s_curve_name, @ i_set_number )dump i_return_value# Get the curve data. I_return_value = @
xy_curve_num_points_get @
( s_curve_name, @
l_yonly, @
i_npoints ) if( I_yonly == false ) thenI_return_value = @
sys_allocate_array(ra_x_array,1,i_npoints)
I_return_value = @
sys_allocate_array(ra_y_array,1,i_npoints)
elseI_return_value = @
sys_allocate_array(ra_y_array,1,i_npoints)
end ifi_return_value = @ xy_curve_data_get @ ( s_curve_name, @ l_yonly, @ i_npoints, @ ra_x_array, @ ra_y_array )dump i_return_valuedump l_yonlydump i_npointsdump ra_x_arraydump ra_y_array#---------------------------------------------------------------------() |
## Purpose : This file provides an example of a call to the# function xy_curve_data_set()## This file opens a new database "new.db" and# creates a window and a curve in it. Finally it# assigns data points to the curve.## This file can be run by starting a session of# Patran, and running this session file # through the "File","Session","Play" pulldown # menus on the menu bar.## The function xy_curve_data_set()# has the following arguments:## xy_curve_data_set# ( curve_name,# yonly,# npoints,# x_array,# y_array )##---------------------------------------------------------------------# Variable DeclarationsSTRING s_text[32]INTEGER i_text_colorSTRING s_window_name[32]REAL r_x_locationREAL r_y_locationREAL r_widthREAL r_heightSTRING s_curve_name[32]LOGICAL l_yonlyINTEGER i_npointsREAL ra_x_array(5)REAL ra_y_array(5)INTEGER i_return_value#---------------------------------------------------------------------# Open a 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.5r_y_location = 3.5r_width = 5.0r_height = 5.0i_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.s_curve_name = "curve_1"s_text = "viscosity"i_text_color = 1i_return_value = @ xy_curve_create @ ( s_curve_name, @ s_text, @ i_text_color )dump i_return_value# Assign data points to the curvel_yonly = FALSEi_npoints = 5ra_x_array = [1., 3., 6., 8., 9.]ra_y_array = [2., 8., 4., 9., 5.]i_return_value = @ xy_curve_data_set @ ( s_curve_name, @ l_yonly, @ i_npoints, @ ra_x_array, @ ra_y_array )dump i_return_value#---------------------------------------------------------------------() |
## Purpose : This file provides an example of a call to the# function xy_curve_list_get()## This file opens a new database "new.db" ,# creates a XY window and gets the list of curves# in it. It then creates a curve and gets the# list of curves again.## This file can be run by starting a session of# Patran, and running this session file # through the "File","Session","Play" pulldown # menus on the menu bar.## The function xy_curve_list_get()# has the following arguments:## xy_curve_list_get# ( curve_list )##---------------------------------------------------------------------# Variable DeclarationsSTRING s_curve_name[32]STRING s_text[32]INTEGER i_text_colorSTRING s_window_name[32]REAL r_x_locationREAL r_y_locationREAL r_widthREAL r_heightSTRING sa_curve_list[32](1)INTEGER i_return_value#---------------------------------------------------------------------# Open a new database "new.db"uil_file_new.go("","new.db")$? YES 36000002# Create a xy window.s_window_name = "XY_Window"r_x_location = 2.5r_y_location = 3.5r_width = 5.0r_height = 5.0i_return_value = @ xy_window_create @ ( s_window_name, @ r_x_location, @ r_y_location, @ r_width, @ r_height )dump i_return_value# Get the list of curves.i_return_value = @ xy_curve_list_get @ ( sa_curve_list )dump i_return_valuedump sa_curve_list# Session file paused. Press "Resume" to continue.sf_pause()# Create a curve.s_curve_name = "new_curve"s_text = "new_curve"i_text_color = 1i_return_value = @ xy_curve_create @ ( s_curve_name, @ s_text, @ i_text_color )dump i_return_value# Assign data points to the curvei_return_value = @ xy_curve_data_set @ ( s_curve_name, FALSE, 5, @ [1., 3., 6., 8., 9.], @ [2., 8., 4., 9., 5.] )dump i_return_value# Get the list of curves.i_return_value = @ xy_curve_list_get @ ( sa_curve_list )dump i_return_valuedump sa_curve_list#---------------------------------------------------------------------() |
## Purpose : This file provides an example of two calls to# the function xy_curve_num_get()## This file opens a new database "new.db" and# counts the number of curves in the xy plot.# Later it creates a curve and gets the count# of curves again.## This file can be run by starting a session of# Patran, and running this session file # through the "File","Session","Play" pulldown # menus on the menu bar.## The function xy_curve_num_get()# has the following arguments:## xy_curve_num_get# ( ncurves )##---------------------------------------------------------------------# Variable DeclarationsSTRING s_curve_name[32]STRING s_text[32]INTEGER i_text_colorINTEGER i_ncurvesSTRING s_window_name[32]REAL r_x_locationREAL r_y_locationREAL r_widthREAL r_heightINTEGER i_return_value#---------------------------------------------------------------------# Open a new database "new.db"uil_file_new.go("","new.db")$? YES 36000002# Create a xy window.s_window_name = "XY_Window"r_x_location = 2.5r_y_location = 3.5r_width = 5.0r_height = 5.0i_return_value = @ xy_window_create @ ( s_window_name, @ r_x_location, @ r_y_location, @ r_width, @ r_height )dump i_return_value# Get the number of curves.i_return_value = @ xy_curve_num_get @ ( i_ncurves )dump i_return_valuedump i_ncurves# Session file paused. Press "Resume" to continue.sf_pause()# Create a curve.s_curve_name = "new_curve"s_text = "new_curve"i_text_color = 1i_return_value = @ xy_curve_create @ ( s_curve_name, @ s_text, @ i_text_color )dump i_return_value# Assign data points to the curvei_return_value = @ xy_curve_data_set @ ( s_curve_name, FALSE, 5, @ [1., 3., 6., 8., 9.], @ [2., 8., 4., 9., 5.] )dump i_return_value# Get the number of curves.i_return_value = @ xy_curve_num_get @ ( i_ncurves )dump i_return_valuedump i_ncurves#---------------------------------------------------------------------() |
## Purpose : This file provides an example of a call to the# function xy_title_create()## This file opens a new database "new.db" and# counts the number of titles in the xy plot.# Later it creates a title and gets the count# of titles again.## This file can be run by starting a session of# Patran, and running this session file# through the "File","Session","Play" pulldown# menus on the menu bar.## The function xy_title_create()# has the following arguments:## xy_title_create# ( title_name,# text,# font_size,# location,# text_color )##---------------------------------------------------------------------# Variable DeclarationsSTRING s_title_name[32]STRING s_text[32]INTEGER i_font_sizeREAL ra_location(2)INTEGER i_text_colorSTRING s_window_name[32]REAL r_x_locationREAL r_y_locationREAL r_widthREAL r_heightINTEGER i_ntitlesINTEGER i_return_value#---------------------------------------------------------------------# Open a new database "new.db"uil_file_new.go("","new.db")$? YES 36000002# Create a xy window.s_window_name = "XY_Window"r_x_location = 2.5r_y_location = 3.5r_width = 5.0r_height = 5.0i_return_value = @ xy_window_create @ ( s_window_name, @ r_x_location, @ r_y_location, @ r_width, @ r_height )dump i_return_value# Count the number of titles.i_return_value = @ xy_title_num_get @ ( i_ntitles )dump i_return_valuedump i_ntitles# Session file paused. Press "Resume" to continue.sf_pause()# Create a Title.s_title_name = "NEW_TITLE"s_text = "NEW_TITLE"i_font_size = 12ra_location(1) = 20ra_location(2) = 10i_text_color = 1i_return_value = @ xy_title_create @ ( s_title_name, @ s_text, @ i_font_size, @ ra_location, @ i_text_color )dump i_return_value# Count the number of titles.i_return_value = @ xy_title_num_get @ ( i_ntitles )dump i_return_valuedump i_ntitles#---------------------------------------------------------------------() |
## Purpose : This file provides an example of a call to the# function xy_title_list_get()## This file opens a new database "new.db" ,# creates a XY window and gets the list of titles# in it. Later it creates a title and gets the# list of titles again.## This file can be run by starting a session of# Patran, and running this session file# through the "File","Session","Play" pulldown# menus on the menu bar.## The function xy_title_list_get()# has the following arguments:## xy_title_list_get# ( title_list )##---------------------------------------------------------------------# Variable DeclarationsSTRING s_title_name[32]STRING s_text[32]INTEGER i_font_sizeREAL ra_location(2)INTEGER i_text_colorSTRING s_window_name[32]REAL r_x_locationREAL r_y_locationREAL r_widthREAL r_heightSTRING sa_title_list[32](1)INTEGER i_return_value#---------------------------------------------------------------------# Open a new database "new.db"uil_file_new.go("","new.db")$? YES 36000002# Create a xy window.s_window_name = "XY_Window"r_x_location = 2.5r_y_location = 3.5r_width = 5.0r_height = 5.0i_return_value = @ xy_window_create @ ( s_window_name, @ r_x_location, @ r_y_location, @ r_width, @ r_height )dump i_return_value# Get the list of titles.i_return_value = @ xy_title_list_get @ ( sa_title_list )dump i_return_valuedump sa_title_list# Session file paused. Press "Resume" to continue.sf_pause()# Create a Title.s_title_name = "NEW_TITLE"s_text = "NEW_TITLE"i_font_size = 12ra_location(1) = 20ra_location(2) = 10i_text_color = 1i_return_value = @ xy_title_create @ ( s_title_name, @ s_text, @ i_font_size, @ ra_location, @ i_text_color )dump i_return_value# Get the list of titles.i_return_value = @ xy_title_list_get @ ( sa_title_list )dump i_return_valuedump sa_title_list#---------------------------------------------------------------------() |
## Purpose : This file provides an example of a call to the# function xy_title_num_get()## This file opens a new database "new.db" and# counts the number of titles in the xy plot.# Later it creates a title and gets the count# of titles again.## This file can be run by starting a session of# Patran, and running this session file# through the "File","Session","Play" pulldown# menus on the menu bar.## The function xy_title_num_get()# has the following arguments:## xy_title_num_get# ( ntitles )##---------------------------------------------------------------------# Variable DeclarationsSTRING s_title_name[32]STRING s_text[32]INTEGER i_font_sizeREAL ra_location(2)INTEGER i_text_colorSTRING s_window_name[32]REAL r_x_locationREAL r_y_locationREAL r_widthREAL r_heightINTEGER i_ntitlesINTEGER i_return_value#---------------------------------------------------------------------# Open a new database "new.db"uil_file_new.go("","new.db")$? YES 36000002# Create a xy window.s_window_name = "XY_Window"r_x_location = 2.5r_y_location = 3.5r_width = 5.0r_height = 5.0i_return_value = @ xy_window_create @ ( s_window_name, @ r_x_location, @ r_y_location, @ r_width, @ r_height )dump i_return_value# Count the number of titles.i_return_value = @ xy_title_num_get @ ( i_ntitles )dump i_return_valuedump i_ntitles# Session file paused. Press "Resume" to continue.sf_pause()# Create a Title.s_title_name = "NEW_TITLE"s_text = "NEW_TITLE"i_font_size = 12ra_location(1) = 20ra_location(2) = 10i_text_color = 1i_return_value = @ xy_title_create @ ( s_title_name, @ s_text, @ i_font_size, @ ra_location, @ i_text_color )dump i_return_value# Count the number of titles.i_return_value = @ xy_title_num_get @ ( i_ntitles )dump i_return_valuedump i_ntitles#---------------------------------------------------------------------() |
## Purpose : This file provides an example of a call to the# function xy_window_create()## This file opens a new database "new.db" and# counts the number of windows. Later it creates# a new XY window and counts the number of# windows again.## This file can be run by starting a session of# Patran, and running this session file # through the "File","Session","Play" pulldown # menus on the menu bar.## The function xy_window_create()# has the following arguments:## xy_window_create# ( window_name,# x_location,# y_location,# width,# height )##---------------------------------------------------------------------# Variable DeclarationsSTRING s_window_name[32]REAL r_x_locationREAL r_y_locationREAL r_widthREAL r_heightINTEGER i_nwindowsINTEGER i_return_value#---------------------------------------------------------------------# Open a new database "new.db"uil_file_new.go("","new.db")$? YES 36000002# Count the number of windows.i_return_value = @ xy_window_num_get @ ( i_nwindows )dump i_return_valuedump i_nwindows# Session file paused. Press "Resume" to continue.sf_pause()# Create a new window.s_window_name = "XY_Window"r_x_location = 2.5r_y_location = 3.5r_width = 5.0r_height = 5.0i_return_value = @ xy_window_create @ ( s_window_name, @ r_x_location, @ r_y_location, @ r_width, @ r_height )dump i_return_value# Count the number of windows.i_return_value = @ xy_window_num_get @ ( i_nwindows )dump i_return_valuedump i_nwindows#---------------------------------------------------------------------() |
## Purpose : This file provides an example of two calls to# the function xy_window_current_get()## This file opens a new database "new.db" and# creates two windows. Later it gets the current# window. Finally it sets the current window and# gets the current window again.## This file can be run by starting a session of# Patran, and running this session file # through the "File","Session","Play" pulldown # menus on the menu bar.## The function xy_window_current_get()# has the following arguments:## xy_window_current_get# ( window_name )##---------------------------------------------------------------------# Variable DeclarationsSTRING s_window_name[32]REAL r_x_locationREAL r_y_locationREAL r_widthREAL r_heightSTRING s_window_name[128]INTEGER i_return_value#---------------------------------------------------------------------# Open a new database "new.db"uil_file_new.go("","new.db")$? YES 36000002# Create two new windows.s_window_name = "XY_Window_1"r_x_location = 2.5r_y_location = 3.5r_width = 5.0r_height = 5.0i_return_value = @ xy_window_create @ ( s_window_name, @ r_x_location, @ r_y_location, @ r_width, @ r_height )dump i_return_values_window_name = "XY_Window_2"r_x_location = 5.r_y_location = 6.i_return_value = @ xy_window_create @ ( s_window_name, @ r_x_location, @ r_y_location, @ r_width, @ r_height )dump i_return_value# Get the current window.s_window_name = ""i_return_value = @ xy_window_current_get @ ( s_window_name )dump i_return_valuedump s_window_name# Session file paused. Press "Resume" to continue..sf_pause()# Set the current window.s_window_name = "XY_Window_1"i_return_value = @ xy_window_current_set @ ( s_window_name )dump i_return_value# Get the current window.s_window_name = ""i_return_value = @ xy_window_current_get @ ( s_window_name )dump i_return_valuedump s_window_name#---------------------------------------------------------------------() |
## Purpose : This file provides an example of a call to the# function xy_window_current_set()## This file opens a new database "new.db" and# creates two windows. Later it gets the current# window. Finally it sets the current window and# gets the current window again.## This file can be run by starting a session of# Patran, and running this session file # through the "File","Session","Play" pulldown # menus on the menu bar.## The function xy_window_current_set()# has the following arguments:## xy_window_current_set# ( window_name )##---------------------------------------------------------------------# Variable DeclarationsSTRING s_window_name[32]REAL r_x_locationREAL r_y_locationREAL r_widthREAL r_heightSTRING s_window_name[128]INTEGER i_return_value#---------------------------------------------------------------------# Open a new database "new.db"uil_file_new.go("","new.db")$? YES 36000002# Create two new windows.s_window_name = "XY_Window_1"r_x_location = 2.5r_y_location = 3.5r_width = 5.0r_height = 5.0i_return_value = @ xy_window_create @ ( s_window_name, @ r_x_location, @ r_y_location, @ r_width, @ r_height )dump i_return_values_window_name = "XY_Window_2"r_x_location = 5.r_y_location = 6.i_return_value = @ xy_window_create @ ( s_window_name, @ r_x_location, @ r_y_location, @ r_width, @ r_height )dump i_return_value# Get the current window.s_window_name = ""i_return_value = @ xy_window_current_get @ ( s_window_name )dump i_return_valuedump s_window_name# Session file paused. Press "Resume" to continue..sf_pause()# Set the current window.s_window_name = "XY_Window_1"i_return_value = @ xy_window_current_set @ ( s_window_name )dump i_return_value# Get the current window.s_window_name = ""i_return_value = @ xy_window_current_get @ ( s_window_name )dump i_return_valuedump s_window_name#---------------------------------------------------------------------() |
## Purpose : This file provides an example of a call to the# function xy_window_list_get()## This file opens a new database "new.db" and# gets the list of XY windows. Later it creates# a new XY window and gets the list of windows# again.## This file can be run by starting a session of# Patran, and running this session file # through the "File","Session","Play" pulldown # menus on the menu bar.## The function xy_window_list_get()# has the following arguments:## xy_window_list_get# ( window_list )##---------------------------------------------------------------------# Variable DeclarationsSTRING s_window_name[32]REAL r_x_locationREAL r_y_locationREAL r_widthREAL r_heightSTRING sa_window_list[32](1)INTEGER i_return_value#---------------------------------------------------------------------# Open a new database "new.db"uil_file_new.go("","new.db")$? YES 36000002# Get the names of windows.i_return_value = @ xy_window_list_get @ ( sa_window_list )dump i_return_valuedump sa_window_list# Session file paused. Press "Resume" to continue.sf_pause()# Create a new window.s_window_name = "XY_Window"r_x_location = 2.5r_y_location = 3.5r_width = 5.0r_height = 5.0i_return_value = @ xy_window_create @ ( s_window_name, @ r_x_location, @ r_y_location, @ r_width, @ r_height )dump i_return_value# Get the names of windows.i_return_value = @ xy_window_list_get @ ( sa_window_list )dump i_return_valuedump sa_window_list#---------------------------------------------------------------------() |
## Purpose : This file provides an example of two calls to# the function xy_window_nposted_get()## This file opens a new database "new.db" and# creates a window. Later it gets the count of# posted windows. Finally it unposts the window# and gets the count of posted windows.## This file can be run by starting a session of# Patran, and running this session file # through the "File","Session","Play" pulldown # menus on the menu bar.## The function xy_window_nposted_get()# has the following arguments:## xy_window_nposted_get# ( nposted )##---------------------------------------------------------------------# Variable DeclarationsSTRING s_window_name[32]REAL r_x_locationREAL r_y_locationREAL r_widthREAL r_heightINTEGER i_npostedINTEGER i_return_value#---------------------------------------------------------------------# Open a 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.5r_y_location = 3.5r_width = 5.0r_height = 5.0i_return_value = @ xy_window_create @ ( s_window_name, @ r_x_location, @ r_y_location, @ r_width, @ r_height )dump i_return_value# Get the number of posted windows.i_return_value = @ xy_window_nposted_get @ ( i_nposted )dump i_return_valuedump i_nposted# Session file paused. Press "Resume" to continue..sf_pause()# Unpost the window.i_return_value = @ xy_window_unpost @ ( s_window_name )dump i_return_value# Get the number of posted windows.i_return_value = @ xy_window_nposted_get @ ( i_nposted )dump i_return_valuedump i_nposted#---------------------------------------------------------------------() |
## Purpose : This file provides an example of a call to the# function xy_window_num_get()## This file opens a new database "new.db" and# counts the number of windows. Later it creates# a new XY window and counts the number of# windows again.## This file can be run by starting a session of# Patran, and running this session file # through the "File","Session","Play" pulldown # menus on the menu bar.## The function xy_window_num_get()# has the following arguments:## xy_window_num_get# ( nwindows )##---------------------------------------------------------------------# Variable DeclarationsSTRING s_window_name[32]REAL r_x_locationREAL r_y_locationREAL r_widthREAL r_heightINTEGER i_nwindowsINTEGER i_return_value#---------------------------------------------------------------------# Open a new database "new.db"uil_file_new.go("","new.db")$? YES 36000002# Count the number of windows.i_return_value = @ xy_window_num_get @ ( i_nwindows )dump i_return_valuedump i_nwindows# Session file paused. Press "Resume" to continue.sf_pause()# Create a new window.s_window_name = "XY_Window"r_x_location = 2.5r_y_location = 3.5r_width = 5.0r_height = 5.0i_return_value = @ xy_window_create @ ( s_window_name, @ r_x_location, @ r_y_location, @ r_width, @ r_height )dump i_return_value# Count the number of windows.i_return_value = @ xy_window_num_get @ ( i_nwindows )dump i_return_valuedump i_nwindows#---------------------------------------------------------------------() |
## Purpose : This file provides an example of a call to the# function xy_window_post()## This file opens a new database "new.db" and# creates a window. Later it unposts the window# and then posts it again.## This file can be run by starting a session of# Patran, and running this session file # through the "File","Session","Play" pulldown # menus on the menu bar.## The function xy_window_post()# has the following arguments:## xy_window_post# ( window_name )##---------------------------------------------------------------------# Variable DeclarationsSTRING s_window_name[128]REAL r_x_locationREAL r_y_locationREAL r_widthREAL r_heightINTEGER i_return_value#---------------------------------------------------------------------# Open a 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.5r_y_location = 3.5r_width = 5.0r_height = 5.0i_return_value = @ xy_window_create @ ( s_window_name, @ r_x_location, @ r_y_location, @ r_width, @ r_height )dump i_return_value# Session file paused. Press "Resume" to continue..sf_pause()# Unpost the window.i_return_value = @ xy_window_unpost @ ( s_window_name )dump i_return_value# Session file paused. Press "Resume" to continue..sf_pause()# Post the window.i_return_value = @ xy_window_post @ ( s_window_name )dump i_return_value#---------------------------------------------------------------------() |
## Purpose : This file provides an example of a call to the# function xy_window_posted_get()## This file opens a new database "new.db" and# creates two new windows and gets the posted# window names. Later it unpost one of the# windows and gets the posted window names again.## This file can be run by starting a session of# Patran, and running this session file # through the "File","Session","Play" pulldown # menus on the menu bar.## The function xy_window_posted_get()# has the following arguments:## xy_window_posted_get# ( posted_list )##---------------------------------------------------------------------# Variable DeclarationsSTRING sa_posted_list[32](2)STRING s_window_name[32]REAL r_x_locationREAL r_y_locationREAL r_widthREAL r_heightINTEGER i_npostedINTEGER i_return_value#---------------------------------------------------------------------# Open a new database "new.db"uil_file_new.go("","new.db")$? YES 36000002# Create two new windows.s_window_name = "XY_Window_1"r_x_location = 2.5r_y_location = 3.5r_width = 5.0r_height = 5.0i_return_value = @ xy_window_create @ ( s_window_name, @ r_x_location, @ r_y_location, @ r_width, @ r_height )dump i_return_values_window_name = "XY_Window_2"r_x_location = 5.r_y_location = 6.i_return_value = @ xy_window_create @ ( s_window_name, @ r_x_location, @ r_y_location, @ r_width, @ r_height )dump i_return_value# Get the names of the posted windows.i_return_value = @ xy_window_posted_get @ ( sa_posted_list )dump i_return_valuedump sa_posted_list# Session file paused. Press "Resume" to continue..sf_pause()# Unpost the window "XY_Window_1"s_window_name = "XY_Window_1"i_return_value = @ xy_window_unpost @ ( s_window_name )dump i_return_value# Get the names of the posted windows.sa_posted_list(1) = ""sa_posted_list(2) = ""i_return_value = @ xy_window_posted_get @ ( sa_posted_list )dump i_return_valuedump sa_posted_list#---------------------------------------------------------------------() |
## Purpose : This file provides an example of a call to the# function xy_window_unpost()## This file opens a new database "new.db" and# creates a window. Later it gets the count of# posted windows. Finally it unposts the window# and gets the count of posted windows.## This file can be run by starting a session of# Patran, and running this session file # through the "File","Session","Play" pulldown # menus on the menu bar.## The function xy_window_unpost()# has the following arguments:## xy_window_unpost# ( window_name )##---------------------------------------------------------------------# Variable DeclarationsSTRING s_window_name[32]REAL r_x_locationREAL r_y_locationREAL r_widthREAL r_heightINTEGER i_npostedINTEGER i_return_value#---------------------------------------------------------------------# Open a 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.5r_y_location = 3.5r_width = 5.0r_height = 5.0i_return_value = @ xy_window_create @ ( s_window_name, @ r_x_location, @ r_y_location, @ r_width, @ r_height )dump i_return_value# Get the number of posted windows.i_return_value = @ xy_window_nposted_get @ ( i_nposted )dump i_return_valuedump i_nposted# Session file paused. Press "Resume" to continue..sf_pause()# Unpost the window.i_return_value = @ xy_window_unpost @ ( s_window_name )dump i_return_value# Get the number of posted windows.i_return_value = @ xy_window_nposted_get @ ( i_nposted )dump i_return_valuedump i_nposted#---------------------------------------------------------------------