news@trantor.harris-atd.com (News stuff) (10/19/90)
Submitted-by: news@trantor.harris-atd.com (News stuff) Posting-number: Volume 10, Issue 8 Archive-name: boss/part06 Path: trantor.harris-atd.com!trantor!chuck From: chuck@trantor.harris-atd.com (Chuck Musciano) Newsgroups: comp.sys.handhelds,comp.sources.x Subject: Boss, part 6/6 Message-ID: <4540@trantor.harris-atd.com> Date: 16 Oct 90 14:12:03 GMT Sender: news@trantor.harris-atd.com Reply-To: chuck@trantor.harris-atd.com (Chuck Musciano) Distribution: world Organization: Advanced Technology Dept, Harris Corp, Melbourne, FL Lines: 1597 #! /bin/sh # This is a shell archive. Remove anything before this line, then unpack # it by saving it into a file and typing "sh file". To overwrite existing # files, type "sh file -c". You can also feed this as standard input via # unshar, or by typing "sh <file", e.g.. If this archive is complete, you # will see the following message at the end: # "End of archive 6 (of 6)." # Contents: boss_ui.c # Wrapped by chuck@melmac on Tue Oct 16 08:53:07 1990 PATH=/bin:/usr/bin:/usr/ucb ; export PATH if test -f 'boss_ui.c' -a "${1}" != "-c" ; then echo shar: Will not clobber existing file \"'boss_ui.c'\" else echo shar: Extracting \"'boss_ui.c'\" \(33639 characters\) sed "s/^X//" >'boss_ui.c' <<'END_OF_FILE' X/************************************************************************/ X/* Copyright 1990 by Chuck Musciano and Harris Corporation */ X/* */ X/* Permission to use, copy, modify, and distribute this software */ X/* and its documentation for any purpose and without fee is */ X/* hereby granted, provided that the above copyright notice */ X/* appear in all copies and that both that copyright notice and */ X/* this permission notice appear in supporting documentation, and */ X/* that the name of Chuck Musciano and Harris Corporation not be */ X/* used in advertising or publicity pertaining to distribution */ X/* of the software without specific, written prior permission. */ X/* Chuck Musciano and Harris Corporation make no representations */ X/* about the suitability of this software for any purpose. It is */ X/* provided "as is" without express or implied warranty. */ X/* */ X/* This code contains data and information that is proprietary */ X/* to Casio Corporation. You may be subject to legal action if */ X/* this information is released without explicit permission from */ X/* Casio. */ X/************************************************************************/ X X/* X * boss_ui.c - User interface object initialization functions. X * This file was generated by `gxv' from `boss.G'. X * DO NOT EDIT BY HAND. X */ X X#include <stdio.h> X#include <sys/param.h> X#include <sys/types.h> X#include <xview/xview.h> X#include <xview/canvas.h> X#include <xview/icon_load.h> X#include <xview/panel.h> X#include <xview/scrollbar.h> X#include <xview/svrimage.h> X#include <xview/termsw.h> X#include <xview/text.h> X#include <xview/tty.h> X#include <xview/xv_xrect.h> X#include "boss_ui.h" X X/* X * Create object `file_menu' in the specified instance. X X */ XXv_opaque Xboss_file_menu_create(ip, owner) X caddr_t *ip; X Xv_opaque owner; X{ X extern Menu_item load_dialog(); X extern Menu_item store_dialog(); X extern Menu_item schedule_dialog(); X Xv_opaque obj; X X obj = xv_create(XV_NULL, MENU_COMMAND_MENU, X XV_KEY_DATA, INSTANCE, ip, X MENU_ITEM, X XV_KEY_DATA, INSTANCE, ip, X MENU_STRING, "Load Data...", X MENU_GEN_PROC, load_dialog, X NULL, X MENU_ITEM, X XV_KEY_DATA, INSTANCE, ip, X MENU_STRING, "Store Data...", X MENU_GEN_PROC, store_dialog, X NULL, X MENU_ITEM, X XV_KEY_DATA, INSTANCE, ip, X MENU_STRING, "Schedule Appointments...", X MENU_GEN_PROC, schedule_dialog, X NULL, X MENU_DEFAULT, 2, X MENU_GEN_PIN_WINDOW, (Xv_opaque) ip[0], "File", X NULL); X return obj; X} X X/* X * Create object `view_menu' in the specified instance. X X */ XXv_opaque Xboss_view_menu_create(ip, owner) X caddr_t *ip; X Xv_opaque owner; X{ X extern Menu_item clear_dialog(); X Xv_opaque obj; X X obj = xv_create(XV_NULL, MENU_COMMAND_MENU, X XV_KEY_DATA, INSTANCE, ip, X MENU_ITEM, X XV_KEY_DATA, INSTANCE, ip, X MENU_STRING, "Clear Data...", X MENU_GEN_PROC, clear_dialog, X NULL, X MENU_DEFAULT, 2, X MENU_GEN_PIN_WINDOW, (Xv_opaque) ip[0], "View", X NULL); X return obj; X} X X/* X * Create object `edit_menu' in the specified instance. X X */ XXv_opaque Xboss_edit_menu_create(ip, owner) X caddr_t *ip; X Xv_opaque owner; X{ X extern Menu_item port_dialog(); X Xv_opaque obj; X X obj = xv_create(XV_NULL, MENU_COMMAND_MENU, X XV_KEY_DATA, INSTANCE, ip, X MENU_ITEM, X XV_KEY_DATA, INSTANCE, ip, X MENU_STRING, "Port properties...", X MENU_GEN_PROC, port_dialog, X NULL, X MENU_DEFAULT, 2, X MENU_GEN_PIN_WINDOW, (Xv_opaque) ip[0], "Edit", X NULL); X return obj; X} X X/* X * Initialize an instance of object `base'. X */ Xboss_base_objects * Xboss_base_objects_initialize(ip, owner) X boss_base_objects *ip; X Xv_opaque owner; X{ X if (!ip && !(ip = (boss_base_objects *) calloc(1, sizeof (boss_base_objects)))) X return (boss_base_objects *) NULL; X if (!ip->base) X ip->base = boss_base_base_create(ip, owner); X if (!ip->main_control) X ip->main_control = boss_base_main_control_create(ip, ip->base); X if (!ip->file_button) X ip->file_button = boss_base_file_button_create(ip, ip->main_control); X if (!ip->view_button) X ip->view_button = boss_base_view_button_create(ip, ip->main_control); X if (!ip->edit_button) X ip->edit_button = boss_base_edit_button_create(ip, ip->main_control); X if (!ip->main_display) X ip->main_display = boss_base_main_display_create(ip, ip->base); X if (!ip->message1) X ip->message1 = boss_base_message1_create(ip, ip->main_display); X if (!ip->message2) X ip->message2 = boss_base_message2_create(ip, ip->main_display); X if (!ip->message3) X ip->message3 = boss_base_message3_create(ip, ip->main_display); X if (!ip->message4) X ip->message4 = boss_base_message4_create(ip, ip->main_display); X if (!ip->message5) X ip->message5 = boss_base_message5_create(ip, ip->main_display); X if (!ip->phone) X ip->phone = boss_base_phone_create(ip, ip->main_display); X if (!ip->schedule) X ip->schedule = boss_base_schedule_create(ip, ip->main_display); X if (!ip->memo) X ip->memo = boss_base_memo_create(ip, ip->main_display); X if (!ip->card) X ip->card = boss_base_card_create(ip, ip->main_display); X if (!ip->calendar) X ip->calendar = boss_base_calendar_create(ip, ip->main_display); X return ip; X} X X/* X * Create object `base' in the specified instance. X X */ XXv_opaque Xboss_base_base_create(ip, owner) X caddr_t ip; X Xv_opaque owner; X{ X Xv_opaque obj; X Xv_opaque base_image; X static unsigned short base_bits[] = { X#include "icons/bosstool.icon" X }; X Xv_opaque base_image_mask; X static unsigned short base_mask_bits[] = { X#include "icons/bosstool_mask.icon" X }; X X base_image = xv_create(XV_NULL, SERVER_IMAGE, X SERVER_IMAGE_BITS, base_bits, X SERVER_IMAGE_DEPTH, 1, X XV_WIDTH, 64, X XV_HEIGHT, 64, X NULL); X base_image_mask = xv_create(XV_NULL, SERVER_IMAGE, X SERVER_IMAGE_BITS, base_mask_bits, X SERVER_IMAGE_DEPTH, 1, X XV_WIDTH, 64, X XV_HEIGHT, 64, X NULL); X obj = xv_create(owner, FRAME, X XV_KEY_DATA, INSTANCE, ip, X XV_WIDTH, 256, X XV_HEIGHT, 88, X XV_LABEL, "Boss 1.0", X FRAME_CLOSED, FALSE, X FRAME_SHOW_FOOTER, FALSE, X FRAME_SHOW_RESIZE_CORNER, FALSE, X FRAME_ICON, xv_create(XV_NULL, ICON, X ICON_IMAGE, base_image, X ICON_MASK_IMAGE, base_image_mask, X NULL), X NULL); X return obj; X} X X/* X * Create object `main_control' in the specified instance. X X */ XXv_opaque Xboss_base_main_control_create(ip, owner) X caddr_t ip; X Xv_opaque owner; X{ X Xv_opaque obj; X X obj = xv_create(owner, PANEL, X XV_KEY_DATA, INSTANCE, ip, X XV_HELP_DATA, "boss:main_control", X XV_X, 0, X XV_Y, 0, X XV_WIDTH, WIN_EXTEND_TO_EDGE, X XV_HEIGHT, 28, X WIN_BORDER, FALSE, X NULL); X return obj; X} X X/* X * Create object `file_button' in the specified instance. X X */ XXv_opaque Xboss_base_file_button_create(ip, owner) X caddr_t ip; X Xv_opaque owner; X{ X Xv_opaque obj; X X obj = xv_create(owner, PANEL_BUTTON, X XV_KEY_DATA, INSTANCE, ip, X XV_HELP_DATA, "boss:file_button", X XV_X, 4, X XV_Y, 4, X XV_WIDTH, 54, X XV_HEIGHT, 20, X PANEL_LABEL_STRING, "File", X PANEL_ITEM_MENU, boss_file_menu_create((caddr_t *) ip, NULL), X NULL); X return obj; X} X X/* X * Create object `view_button' in the specified instance. X X */ XXv_opaque Xboss_base_view_button_create(ip, owner) X caddr_t ip; X Xv_opaque owner; X{ X Xv_opaque obj; X X obj = xv_create(owner, PANEL_BUTTON, X XV_KEY_DATA, INSTANCE, ip, X XV_HELP_DATA, "boss:view_button", X XV_X, 67, X XV_Y, 4, X XV_WIDTH, 62, X XV_HEIGHT, 20, X PANEL_LABEL_STRING, "View", X PANEL_ITEM_MENU, boss_view_menu_create((caddr_t *) ip, NULL), X NULL); X return obj; X} X X/* X * Create object `edit_button' in the specified instance. X X */ XXv_opaque Xboss_base_edit_button_create(ip, owner) X caddr_t ip; X Xv_opaque owner; X{ X Xv_opaque obj; X X obj = xv_create(owner, PANEL_BUTTON, X XV_KEY_DATA, INSTANCE, ip, X XV_HELP_DATA, "boss:edit_button", X XV_X, 138, X XV_Y, 4, X XV_WIDTH, 56, X XV_HEIGHT, 20, X PANEL_LABEL_STRING, "Edit", X PANEL_ITEM_MENU, boss_edit_menu_create((caddr_t *) ip, NULL), X NULL); X return obj; X} X X/* X * Create object `main_display' in the specified instance. X X */ XXv_opaque Xboss_base_main_display_create(ip, owner) X caddr_t ip; X Xv_opaque owner; X{ X Xv_opaque obj; X X obj = xv_create(owner, PANEL, X XV_KEY_DATA, INSTANCE, ip, X XV_HELP_DATA, "boss:main_display", X XV_X, 0, X XV_Y, 28, X XV_WIDTH, WIN_EXTEND_TO_EDGE, X XV_HEIGHT, WIN_EXTEND_TO_EDGE, X WIN_BORDER, TRUE, X NULL); X return obj; X} X X/* X * Create object `message1' in the specified instance. X X */ XXv_opaque Xboss_base_message1_create(ip, owner) X caddr_t ip; X Xv_opaque owner; X{ X Xv_opaque obj; X Xv_opaque message1_image; X static unsigned short message1_bits[] = { X#include "icons/phone.icon" X }; X X message1_image = xv_create(XV_NULL, SERVER_IMAGE, X SERVER_IMAGE_BITS, message1_bits, X SERVER_IMAGE_DEPTH, 1, X XV_WIDTH, 32, X XV_HEIGHT, 24, X NULL); X obj = xv_create(owner, PANEL_MESSAGE, X XV_KEY_DATA, INSTANCE, ip, X XV_HELP_DATA, "boss:message1", X XV_X, 16, X XV_Y, 8, X XV_WIDTH, 32, X XV_HEIGHT, 24, X PANEL_LABEL_IMAGE, message1_image, X PANEL_LABEL_BOLD, TRUE, X NULL); X return obj; X} X X/* X * Create object `message2' in the specified instance. X X */ XXv_opaque Xboss_base_message2_create(ip, owner) X caddr_t ip; X Xv_opaque owner; X{ X Xv_opaque obj; X Xv_opaque message2_image; X static unsigned short message2_bits[] = { X#include "icons/schedule.icon" X }; X X message2_image = xv_create(XV_NULL, SERVER_IMAGE, X SERVER_IMAGE_BITS, message2_bits, X SERVER_IMAGE_DEPTH, 1, X XV_WIDTH, 32, X XV_HEIGHT, 24, X NULL); X obj = xv_create(owner, PANEL_MESSAGE, X XV_KEY_DATA, INSTANCE, ip, X XV_HELP_DATA, "boss:message2", X XV_X, 64, X XV_Y, 8, X XV_WIDTH, 32, X XV_HEIGHT, 24, X PANEL_LABEL_IMAGE, message2_image, X PANEL_LABEL_BOLD, TRUE, X NULL); X return obj; X} X X/* X * Create object `message3' in the specified instance. X X */ XXv_opaque Xboss_base_message3_create(ip, owner) X caddr_t ip; X Xv_opaque owner; X{ X Xv_opaque obj; X Xv_opaque message3_image; X static unsigned short message3_bits[] = { X#include "icons/memo.icon" X }; X X message3_image = xv_create(XV_NULL, SERVER_IMAGE, X SERVER_IMAGE_BITS, message3_bits, X SERVER_IMAGE_DEPTH, 1, X XV_WIDTH, 32, X XV_HEIGHT, 24, X NULL); X obj = xv_create(owner, PANEL_MESSAGE, X XV_KEY_DATA, INSTANCE, ip, X XV_HELP_DATA, "boss:message3", X XV_X, 112, X XV_Y, 8, X XV_WIDTH, 32, X XV_HEIGHT, 24, X PANEL_LABEL_IMAGE, message3_image, X PANEL_LABEL_BOLD, TRUE, X NULL); X return obj; X} X X/* X * Create object `message4' in the specified instance. X X */ XXv_opaque Xboss_base_message4_create(ip, owner) X caddr_t ip; X Xv_opaque owner; X{ X Xv_opaque obj; X Xv_opaque message4_image; X static unsigned short message4_bits[] = { X#include "icons/card.icon" X }; X X message4_image = xv_create(XV_NULL, SERVER_IMAGE, X SERVER_IMAGE_BITS, message4_bits, X SERVER_IMAGE_DEPTH, 1, X XV_WIDTH, 32, X XV_HEIGHT, 24, X NULL); X obj = xv_create(owner, PANEL_MESSAGE, X XV_KEY_DATA, INSTANCE, ip, X XV_HELP_DATA, "boss:message4", X XV_X, 160, X XV_Y, 8, X XV_WIDTH, 32, X XV_HEIGHT, 24, X PANEL_LABEL_IMAGE, message4_image, X PANEL_LABEL_BOLD, TRUE, X NULL); X return obj; X} X X/* X * Create object `message5' in the specified instance. X X */ XXv_opaque Xboss_base_message5_create(ip, owner) X caddr_t ip; X Xv_opaque owner; X{ X Xv_opaque obj; X Xv_opaque message5_image; X static unsigned short message5_bits[] = { X#include "icons/calendar.icon" X }; X X message5_image = xv_create(XV_NULL, SERVER_IMAGE, X SERVER_IMAGE_BITS, message5_bits, X SERVER_IMAGE_DEPTH, 1, X XV_WIDTH, 32, X XV_HEIGHT, 24, X NULL); X obj = xv_create(owner, PANEL_MESSAGE, X XV_KEY_DATA, INSTANCE, ip, X XV_HELP_DATA, "boss:message5", X XV_X, 208, X XV_Y, 8, X XV_WIDTH, 32, X XV_HEIGHT, 24, X PANEL_LABEL_IMAGE, message5_image, X PANEL_LABEL_BOLD, TRUE, X NULL); X return obj; X} X X/* X * Create object `phone' in the specified instance. X X */ XXv_opaque Xboss_base_phone_create(ip, owner) X caddr_t ip; X Xv_opaque owner; X{ X Xv_opaque obj; X X obj = xv_create(owner, PANEL_MESSAGE, X XV_KEY_DATA, INSTANCE, ip, X XV_HELP_DATA, "boss:phone", X XV_X, 28, X XV_Y, 40, X XV_WIDTH, 9, X XV_HEIGHT, 13, X PANEL_LABEL_STRING, "0", X PANEL_LABEL_BOLD, TRUE, X NULL); X return obj; X} X X/* X * Create object `schedule' in the specified instance. X X */ XXv_opaque Xboss_base_schedule_create(ip, owner) X caddr_t ip; X Xv_opaque owner; X{ X Xv_opaque obj; X X obj = xv_create(owner, PANEL_MESSAGE, X XV_KEY_DATA, INSTANCE, ip, X XV_HELP_DATA, "boss:schedule", X XV_X, 76, X XV_Y, 40, X XV_WIDTH, 9, X XV_HEIGHT, 13, X PANEL_LABEL_STRING, "0", X PANEL_LABEL_BOLD, TRUE, X NULL); X return obj; X} X X/* X * Create object `memo' in the specified instance. X X */ XXv_opaque Xboss_base_memo_create(ip, owner) X caddr_t ip; X Xv_opaque owner; X{ X Xv_opaque obj; X X obj = xv_create(owner, PANEL_MESSAGE, X XV_KEY_DATA, INSTANCE, ip, X XV_HELP_DATA, "boss:memo", X XV_X, 124, X XV_Y, 40, X XV_WIDTH, 9, X XV_HEIGHT, 13, X PANEL_LABEL_STRING, "0", X PANEL_LABEL_BOLD, TRUE, X NULL); X return obj; X} X X/* X * Create object `card' in the specified instance. X X */ XXv_opaque Xboss_base_card_create(ip, owner) X caddr_t ip; X Xv_opaque owner; X{ X Xv_opaque obj; X X obj = xv_create(owner, PANEL_MESSAGE, X XV_KEY_DATA, INSTANCE, ip, X XV_HELP_DATA, "boss:card", X XV_X, 172, X XV_Y, 40, X XV_WIDTH, 9, X XV_HEIGHT, 13, X PANEL_LABEL_STRING, "0", X PANEL_LABEL_BOLD, TRUE, X NULL); X return obj; X} X X/* X * Create object `calendar' in the specified instance. X X */ XXv_opaque Xboss_base_calendar_create(ip, owner) X caddr_t ip; X Xv_opaque owner; X{ X Xv_opaque obj; X X obj = xv_create(owner, PANEL_MESSAGE, X XV_KEY_DATA, INSTANCE, ip, X XV_HELP_DATA, "boss:calendar", X XV_X, 220, X XV_Y, 40, X XV_WIDTH, 9, X XV_HEIGHT, 13, X PANEL_LABEL_STRING, "0", X PANEL_LABEL_BOLD, TRUE, X NULL); X return obj; X} X X/* X * Initialize an instance of object `load_dialog'. X */ Xboss_load_dialog_objects * Xboss_load_dialog_objects_initialize(ip, owner) X boss_load_dialog_objects *ip; X Xv_opaque owner; X{ X if (!ip && !(ip = (boss_load_dialog_objects *) calloc(1, sizeof (boss_load_dialog_objects)))) X return (boss_load_dialog_objects *) NULL; X if (!ip->load_dialog) X ip->load_dialog = boss_load_dialog_load_dialog_create(ip, owner); X if (!ip->load_control) X ip->load_control = boss_load_dialog_load_control_create(ip, ip->load_dialog); X if (!ip->source) X ip->source = boss_load_dialog_source_create(ip, ip->load_control); X if (!ip->casio_source) X ip->casio_source = boss_load_dialog_casio_source_create(ip, ip->load_control); X if (!ip->ascii_source) X ip->ascii_source = boss_load_dialog_ascii_source_create(ip, ip->load_control); X if (!ip->load_accept) X ip->load_accept = boss_load_dialog_load_accept_create(ip, ip->load_control); X return ip; X} X X/* X * Create object `load_dialog' in the specified instance. X X */ XXv_opaque Xboss_load_dialog_load_dialog_create(ip, owner) X caddr_t ip; X Xv_opaque owner; X{ X Xv_opaque obj; X X obj = xv_create(owner, FRAME_CMD, X XV_KEY_DATA, INSTANCE, ip, X XV_WIDTH, 509, X XV_HEIGHT, 136, X XV_LABEL, "Boss: Load Data", X XV_SHOW, FALSE, X FRAME_SHOW_FOOTER, FALSE, X FRAME_SHOW_RESIZE_CORNER, FALSE, X FRAME_CMD_PUSHPIN_IN, FALSE, X NULL); X xv_set(xv_get(obj, FRAME_CMD_PANEL), WIN_SHOW, FALSE, NULL); X return obj; X} X X/* X * Create object `load_control' in the specified instance. X X */ XXv_opaque Xboss_load_dialog_load_control_create(ip, owner) X caddr_t ip; X Xv_opaque owner; X{ X Xv_opaque obj; X X obj = xv_create(owner, PANEL, X XV_KEY_DATA, INSTANCE, ip, X XV_HELP_DATA, "boss:load_control", X XV_X, 0, X XV_Y, 0, X XV_WIDTH, WIN_EXTEND_TO_EDGE, X XV_HEIGHT, WIN_EXTEND_TO_EDGE, X WIN_BORDER, FALSE, X NULL); X return obj; X} X X/* X * Create object `source' in the specified instance. X X */ XXv_opaque Xboss_load_dialog_source_create(ip, owner) X caddr_t ip; X Xv_opaque owner; X{ X extern int load_notify(); X Xv_opaque obj; X X obj = xv_create(owner, PANEL_CHOICE, X XV_KEY_DATA, INSTANCE, ip, X XV_HELP_DATA, "boss:source", X XV_X, 14, X XV_Y, 14, X XV_WIDTH, 236, X XV_HEIGHT, 67, X PANEL_VALUE_X, 128, X PANEL_VALUE_Y, 14, X PANEL_LAYOUT, PANEL_HORIZONTAL, X PANEL_CHOICE_NCOLS, 1, X PANEL_LABEL_STRING, "Load data from:", X PANEL_NOTIFY_PROC, load_notify, X PANEL_CHOICE_STRINGS, X "Casio BOSS", X "Casio-format file", X "ASCII text file", X 0, X NULL); X return obj; X} X X/* X * Create object `casio_source' in the specified instance. X X */ XXv_opaque Xboss_load_dialog_casio_source_create(ip, owner) X caddr_t ip; X Xv_opaque owner; X{ X extern Panel_setting filename_completion(); X Xv_opaque obj; X X obj = xv_create(owner, PANEL_TEXT, X XV_KEY_DATA, INSTANCE, ip, X XV_HELP_DATA, "boss:casio_source", X XV_X, 246, X XV_Y, 41, X XV_WIDTH, 249, X XV_HEIGHT, 15, X PANEL_VALUE_X, 255, X PANEL_VALUE_Y, 41, X PANEL_LAYOUT, PANEL_HORIZONTAL, X PANEL_VALUE_DISPLAY_LENGTH, 30, X PANEL_VALUE_STORED_LENGTH, 256, X PANEL_READ_ONLY, FALSE, X PANEL_NOTIFY_PROC, filename_completion, X NULL); X return obj; X} X X/* X * Create object `ascii_source' in the specified instance. X X */ XXv_opaque Xboss_load_dialog_ascii_source_create(ip, owner) X caddr_t ip; X Xv_opaque owner; X{ X extern Panel_setting filename_completion(); X Xv_opaque obj; X X obj = xv_create(owner, PANEL_TEXT, X XV_KEY_DATA, INSTANCE, ip, X XV_HELP_DATA, "boss:ascii_source", X XV_X, 246, X XV_Y, 63, X XV_WIDTH, 249, X XV_HEIGHT, 15, X PANEL_VALUE_X, 255, X PANEL_VALUE_Y, 63, X PANEL_LAYOUT, PANEL_HORIZONTAL, X PANEL_VALUE_DISPLAY_LENGTH, 30, X PANEL_VALUE_STORED_LENGTH, 256, X PANEL_READ_ONLY, FALSE, X PANEL_NOTIFY_PROC, filename_completion, X NULL); X return obj; X} X X/* X * Create object `load_accept' in the specified instance. X X */ XXv_opaque Xboss_load_dialog_load_accept_create(ip, owner) X caddr_t ip; X Xv_opaque owner; X{ X extern void accept_load(); X Xv_opaque obj; X X obj = xv_create(owner, PANEL_BUTTON, X XV_KEY_DATA, INSTANCE, ip, X XV_HELP_DATA, "boss:load_accept", X XV_X, 231, X XV_Y, 102, X XV_WIDTH, 46, X XV_HEIGHT, 20, X PANEL_LABEL_STRING, "Load", X PANEL_NOTIFY_PROC, accept_load, X NULL); X return obj; X} X X/* X * Initialize an instance of object `store_dialog'. X */ Xboss_store_dialog_objects * Xboss_store_dialog_objects_initialize(ip, owner) X boss_store_dialog_objects *ip; X Xv_opaque owner; X{ X if (!ip && !(ip = (boss_store_dialog_objects *) calloc(1, sizeof (boss_store_dialog_objects)))) X return (boss_store_dialog_objects *) NULL; X if (!ip->store_dialog) X ip->store_dialog = boss_store_dialog_store_dialog_create(ip, owner); X if (!ip->store_control) X ip->store_control = boss_store_dialog_store_control_create(ip, ip->store_dialog); X if (!ip->store_data) X ip->store_data = boss_store_dialog_store_data_create(ip, ip->store_control); X if (!ip->dest) X ip->dest = boss_store_dialog_dest_create(ip, ip->store_control); X if (!ip->casio_dest) X ip->casio_dest = boss_store_dialog_casio_dest_create(ip, ip->store_control); X if (!ip->ascii_dest) X ip->ascii_dest = boss_store_dialog_ascii_dest_create(ip, ip->store_control); X if (!ip->store_accept) X ip->store_accept = boss_store_dialog_store_accept_create(ip, ip->store_control); X return ip; X} X X/* X * Create object `store_dialog' in the specified instance. X X */ XXv_opaque Xboss_store_dialog_store_dialog_create(ip, owner) X caddr_t ip; X Xv_opaque owner; X{ X Xv_opaque obj; X X obj = xv_create(owner, FRAME_CMD, X XV_KEY_DATA, INSTANCE, ip, X XV_WIDTH, 492, X XV_HEIGHT, 238, X XV_LABEL, "Boss: Store Data", X XV_SHOW, FALSE, X FRAME_SHOW_FOOTER, FALSE, X FRAME_SHOW_RESIZE_CORNER, FALSE, X FRAME_CMD_PUSHPIN_IN, FALSE, X NULL); X xv_set(xv_get(obj, FRAME_CMD_PANEL), WIN_SHOW, FALSE, NULL); X return obj; X} X X/* X * Create object `store_control' in the specified instance. X X */ XXv_opaque Xboss_store_dialog_store_control_create(ip, owner) X caddr_t ip; X Xv_opaque owner; X{ X Xv_opaque obj; X X obj = xv_create(owner, PANEL, X XV_KEY_DATA, INSTANCE, ip, X XV_HELP_DATA, "boss:store_control", X XV_X, 0, X XV_Y, 0, X XV_WIDTH, WIN_EXTEND_TO_EDGE, X XV_HEIGHT, WIN_EXTEND_TO_EDGE, X WIN_BORDER, FALSE, X NULL); X return obj; X} X X/* X * Create object `store_data' in the specified instance. X X */ XXv_opaque Xboss_store_dialog_store_data_create(ip, owner) X caddr_t ip; X Xv_opaque owner; X{ X Xv_opaque obj; X X obj = xv_create(owner, PANEL_TOGGLE, X XV_KEY_DATA, INSTANCE, ip, X XV_HELP_DATA, "boss:store_data", X XV_X, 21, X XV_Y, 14, X XV_WIDTH, 399, X XV_HEIGHT, 81, X PANEL_VALUE_X, 111, X PANEL_VALUE_Y, 14, X PANEL_LAYOUT, PANEL_HORIZONTAL, X PANEL_CHOICE_NCOLS, 2, X PANEL_LABEL_STRING, "Store items:", X PANEL_CHOICE_STRINGS, X "Telephone numbers", X "Schedule entries", X "Memo entries", X "Business Cards", X "Marked calendar days", X 0, X NULL); X return obj; X} X X/* X * Create object `dest' in the specified instance. X X */ XXv_opaque Xboss_store_dialog_dest_create(ip, owner) X caddr_t ip; X Xv_opaque owner; X{ X extern int store_notify(); X Xv_opaque obj; X X obj = xv_create(owner, PANEL_CHOICE, X XV_KEY_DATA, INSTANCE, ip, X XV_HELP_DATA, "boss:dest", X XV_X, 14, X XV_Y, 116, X XV_WIDTH, 219, X XV_HEIGHT, 67, X PANEL_VALUE_X, 111, X PANEL_VALUE_Y, 116, X PANEL_LAYOUT, PANEL_HORIZONTAL, X PANEL_CHOICE_NCOLS, 1, X PANEL_LABEL_STRING, "Store data to:", X PANEL_NOTIFY_PROC, store_notify, X PANEL_CHOICE_STRINGS, X "Casio BOSS", X "Casio-format file", X "ASCII text file", X 0, X NULL); X return obj; X} X X/* X * Create object `casio_dest' in the specified instance. X X */ XXv_opaque Xboss_store_dialog_casio_dest_create(ip, owner) X caddr_t ip; X Xv_opaque owner; X{ X extern Panel_setting filename_completion(); X Xv_opaque obj; X X obj = xv_create(owner, PANEL_TEXT, X XV_KEY_DATA, INSTANCE, ip, X XV_HELP_DATA, "boss:casio_dest", X XV_X, 229, X XV_Y, 143, X XV_WIDTH, 249, X XV_HEIGHT, 15, X PANEL_VALUE_X, 238, X PANEL_VALUE_Y, 143, X PANEL_LAYOUT, PANEL_HORIZONTAL, X PANEL_VALUE_DISPLAY_LENGTH, 30, X PANEL_VALUE_STORED_LENGTH, 256, X PANEL_READ_ONLY, FALSE, X PANEL_NOTIFY_PROC, filename_completion, X NULL); X return obj; X} X X/* X * Create object `ascii_dest' in the specified instance. X X */ XXv_opaque Xboss_store_dialog_ascii_dest_create(ip, owner) X caddr_t ip; X Xv_opaque owner; X{ X extern Panel_setting filename_completion(); X Xv_opaque obj; X X obj = xv_create(owner, PANEL_TEXT, X XV_KEY_DATA, INSTANCE, ip, X XV_HELP_DATA, "boss:ascii_dest", X XV_X, 229, X XV_Y, 165, X XV_WIDTH, 249, X XV_HEIGHT, 15, X PANEL_VALUE_X, 238, X PANEL_VALUE_Y, 165, X PANEL_LAYOUT, PANEL_HORIZONTAL, X PANEL_VALUE_DISPLAY_LENGTH, 30, X PANEL_VALUE_STORED_LENGTH, 256, X PANEL_READ_ONLY, FALSE, X PANEL_NOTIFY_PROC, filename_completion, X NULL); X return obj; X} X X/* X * Create object `store_accept' in the specified instance. X X */ XXv_opaque Xboss_store_dialog_store_accept_create(ip, owner) X caddr_t ip; X Xv_opaque owner; X{ X extern void accept_store(); X Xv_opaque obj; X X obj = xv_create(owner, PANEL_BUTTON, X XV_KEY_DATA, INSTANCE, ip, X XV_HELP_DATA, "boss:store_accept", X XV_X, 221, X XV_Y, 204, X XV_WIDTH, 49, X XV_HEIGHT, 20, X PANEL_LABEL_STRING, "Store", X PANEL_NOTIFY_PROC, accept_store, X NULL); X return obj; X} X X/* X * Initialize an instance of object `clear_dialog'. X */ Xboss_clear_dialog_objects * Xboss_clear_dialog_objects_initialize(ip, owner) X boss_clear_dialog_objects *ip; X Xv_opaque owner; X{ X if (!ip && !(ip = (boss_clear_dialog_objects *) calloc(1, sizeof (boss_clear_dialog_objects)))) X return (boss_clear_dialog_objects *) NULL; X if (!ip->clear_dialog) X ip->clear_dialog = boss_clear_dialog_clear_dialog_create(ip, owner); X if (!ip->clear_control) X ip->clear_control = boss_clear_dialog_clear_control_create(ip, ip->clear_dialog); X if (!ip->clear_data) X ip->clear_data = boss_clear_dialog_clear_data_create(ip, ip->clear_control); X if (!ip->clear_accept) X ip->clear_accept = boss_clear_dialog_clear_accept_create(ip, ip->clear_control); X return ip; X} X X/* X * Create object `clear_dialog' in the specified instance. X X */ XXv_opaque Xboss_clear_dialog_clear_dialog_create(ip, owner) X caddr_t ip; X Xv_opaque owner; X{ X Xv_opaque obj; X X obj = xv_create(owner, FRAME_CMD, X XV_KEY_DATA, INSTANCE, ip, X XV_WIDTH, 428, X XV_HEIGHT, 143, X XV_LABEL, "Boss: Clear Data", X XV_SHOW, FALSE, X FRAME_SHOW_FOOTER, FALSE, X FRAME_SHOW_RESIZE_CORNER, FALSE, X FRAME_CMD_PUSHPIN_IN, FALSE, X NULL); X xv_set(xv_get(obj, FRAME_CMD_PANEL), WIN_SHOW, FALSE, NULL); X return obj; X} X X/* X * Create object `clear_control' in the specified instance. X X */ XXv_opaque Xboss_clear_dialog_clear_control_create(ip, owner) X caddr_t ip; X Xv_opaque owner; X{ X Xv_opaque obj; X X obj = xv_create(owner, PANEL, X XV_KEY_DATA, INSTANCE, ip, X XV_HELP_DATA, "boss:clear_control", X XV_X, 0, X XV_Y, 0, X XV_WIDTH, WIN_EXTEND_TO_EDGE, X XV_HEIGHT, WIN_EXTEND_TO_EDGE, X WIN_BORDER, FALSE, X NULL); X return obj; X} X X/* X * Create object `clear_data' in the specified instance. X X */ XXv_opaque Xboss_clear_dialog_clear_data_create(ip, owner) X caddr_t ip; X Xv_opaque owner; X{ X Xv_opaque obj; X X obj = xv_create(owner, PANEL_TOGGLE, X XV_KEY_DATA, INSTANCE, ip, X XV_HELP_DATA, "boss:clear_data", X XV_X, 14, X XV_Y, 14, X XV_WIDTH, 400, X XV_HEIGHT, 81, X PANEL_VALUE_X, 105, X PANEL_VALUE_Y, 14, X PANEL_LAYOUT, PANEL_HORIZONTAL, X PANEL_CHOICE_NCOLS, 2, X PANEL_LABEL_STRING, "Clear items:", X PANEL_CHOICE_STRINGS, X "Telephone numbers", X "Schedule entries", X "Memo entries", X "Business Cards", X "Marked calendar days", X 0, X NULL); X return obj; X} X X/* X * Create object `clear_accept' in the specified instance. X X */ XXv_opaque Xboss_clear_dialog_clear_accept_create(ip, owner) X caddr_t ip; X Xv_opaque owner; X{ X extern void accept_clear(); X Xv_opaque obj; X X obj = xv_create(owner, PANEL_BUTTON, X XV_KEY_DATA, INSTANCE, ip, X XV_HELP_DATA, "boss:clear_accept", X XV_X, 189, X XV_Y, 109, X XV_WIDTH, 50, X XV_HEIGHT, 20, X PANEL_LABEL_STRING, "Clear", X PANEL_NOTIFY_PROC, accept_clear, X NULL); X return obj; X} X X/* X * Initialize an instance of object `port_dialog'. X */ Xboss_port_dialog_objects * Xboss_port_dialog_objects_initialize(ip, owner) X boss_port_dialog_objects *ip; X Xv_opaque owner; X{ X if (!ip && !(ip = (boss_port_dialog_objects *) calloc(1, sizeof (boss_port_dialog_objects)))) X return (boss_port_dialog_objects *) NULL; X if (!ip->port_dialog) X ip->port_dialog = boss_port_dialog_port_dialog_create(ip, owner); X if (!ip->port_control) X ip->port_control = boss_port_dialog_port_control_create(ip, ip->port_dialog); X if (!ip->port_port) X ip->port_port = boss_port_dialog_port_port_create(ip, ip->port_control); X if (!ip->port_baud) X ip->port_baud = boss_port_dialog_port_baud_create(ip, ip->port_control); X if (!ip->port_parity) X ip->port_parity = boss_port_dialog_port_parity_create(ip, ip->port_control); X if (!ip->port_accept) X ip->port_accept = boss_port_dialog_port_accept_create(ip, ip->port_control); X if (!ip->port_reset) X ip->port_reset = boss_port_dialog_port_reset_create(ip, ip->port_control); X return ip; X} X X/* X * Create object `port_dialog' in the specified instance. X X */ XXv_opaque Xboss_port_dialog_port_dialog_create(ip, owner) X caddr_t ip; X Xv_opaque owner; X{ X Xv_opaque obj; X X obj = xv_create(owner, FRAME_CMD, X XV_KEY_DATA, INSTANCE, ip, X XV_WIDTH, 301, X XV_HEIGHT, 141, X XV_LABEL, "Boss: Port Properties", X XV_SHOW, FALSE, X FRAME_SHOW_FOOTER, FALSE, X FRAME_SHOW_RESIZE_CORNER, FALSE, X FRAME_CMD_PUSHPIN_IN, FALSE, X NULL); X xv_set(xv_get(obj, FRAME_CMD_PANEL), WIN_SHOW, FALSE, NULL); X return obj; X} X X/* X * Create object `port_control' in the specified instance. X X */ XXv_opaque Xboss_port_dialog_port_control_create(ip, owner) X caddr_t ip; X Xv_opaque owner; X{ X Xv_opaque obj; X X obj = xv_create(owner, PANEL, X XV_KEY_DATA, INSTANCE, ip, X XV_HELP_DATA, "boss:port_control", X XV_X, 0, X XV_Y, 0, X XV_WIDTH, WIN_EXTEND_TO_EDGE, X XV_HEIGHT, WIN_EXTEND_TO_EDGE, X WIN_BORDER, FALSE, X NULL); X return obj; X} X X/* X * Create object `port_port' in the specified instance. X X */ XXv_opaque Xboss_port_dialog_port_port_create(ip, owner) X caddr_t ip; X Xv_opaque owner; X{ X Xv_opaque obj; X X obj = xv_create(owner, PANEL_CHOICE, X XV_KEY_DATA, INSTANCE, ip, X XV_HELP_DATA, "boss:port_port", X XV_X, 14, X XV_Y, 14, X XV_WIDTH, 232, X XV_HEIGHT, 23, X PANEL_VALUE_X, 98, X PANEL_VALUE_Y, 14, X PANEL_LAYOUT, PANEL_HORIZONTAL, X PANEL_CHOICE_NROWS, 1, X PANEL_LABEL_STRING, "Serial port:", X PANEL_CHOICE_STRINGS, X "/dev/ttya", X "/dev/ttyb", X 0, X NULL); X return obj; X} X X/* X * Create object `port_baud' in the specified instance. X X */ XXv_opaque Xboss_port_dialog_port_baud_create(ip, owner) X caddr_t ip; X Xv_opaque owner; X{ X Xv_opaque obj; X X obj = xv_create(owner, PANEL_CHOICE, X XV_KEY_DATA, INSTANCE, ip, X XV_HELP_DATA, "boss:port_baud", X XV_X, 21, X XV_Y, 42, X XV_WIDTH, 266, X XV_HEIGHT, 23, X PANEL_VALUE_X, 98, X PANEL_VALUE_Y, 42, X PANEL_LAYOUT, PANEL_HORIZONTAL, X PANEL_CHOICE_NROWS, 1, X PANEL_LABEL_STRING, "Baud rate:", X PANEL_CHOICE_STRINGS, X "1200", X "2400", X "4800", X "9600", X 0, X NULL); X return obj; X} X X/* X * Create object `port_parity' in the specified instance. X X */ XXv_opaque Xboss_port_dialog_port_parity_create(ip, owner) X caddr_t ip; X Xv_opaque owner; X{ X Xv_opaque obj; X X obj = xv_create(owner, PANEL_CHOICE, X XV_KEY_DATA, INSTANCE, ip, X XV_HELP_DATA, "boss:port_parity", X XV_X, 46, X XV_Y, 70, X XV_WIDTH, 184, X XV_HEIGHT, 23, X PANEL_VALUE_X, 98, X PANEL_VALUE_Y, 70, X PANEL_LAYOUT, PANEL_HORIZONTAL, X PANEL_CHOICE_NROWS, 1, X PANEL_LABEL_STRING, "Parity:", X PANEL_CHOICE_STRINGS, X "Even", X "Odd", X "None", X 0, X NULL); X return obj; X} X X/* X * Create object `port_accept' in the specified instance. X X */ XXv_opaque Xboss_port_dialog_port_accept_create(ip, owner) X caddr_t ip; X Xv_opaque owner; X{ X extern void accept_port(); X Xv_opaque obj; X X obj = xv_create(owner, PANEL_BUTTON, X XV_KEY_DATA, INSTANCE, ip, X XV_HELP_DATA, "boss:port_accept", X XV_X, 91, X XV_Y, 107, X XV_WIDTH, 53, X XV_HEIGHT, 20, X PANEL_LABEL_STRING, "Apply", X PANEL_NOTIFY_PROC, accept_port, X NULL); X return obj; X} X X/* X * Create object `port_reset' in the specified instance. X X */ XXv_opaque Xboss_port_dialog_port_reset_create(ip, owner) X caddr_t ip; X Xv_opaque owner; X{ X extern void reset_port(); X Xv_opaque obj; X X obj = xv_create(owner, PANEL_BUTTON, X XV_KEY_DATA, INSTANCE, ip, X XV_HELP_DATA, "boss:port_reset", X XV_X, 158, X XV_Y, 107, X XV_WIDTH, 51, X XV_HEIGHT, 20, X PANEL_LABEL_STRING, "Reset", X PANEL_NOTIFY_PROC, reset_port, X NULL); X return obj; X} X X/* X * Initialize an instance of object `schedule_dialog'. X */ Xboss_schedule_dialog_objects * Xboss_schedule_dialog_objects_initialize(ip, owner) X boss_schedule_dialog_objects *ip; X Xv_opaque owner; X{ X if (!ip && !(ip = (boss_schedule_dialog_objects *) calloc(1, sizeof (boss_schedule_dialog_objects)))) X return (boss_schedule_dialog_objects *) NULL; X if (!ip->schedule_dialog) X ip->schedule_dialog = boss_schedule_dialog_schedule_dialog_create(ip, owner); X if (!ip->schedule_control) X ip->schedule_control = boss_schedule_dialog_schedule_control_create(ip, ip->schedule_dialog); X if (!ip->schedule_format) X ip->schedule_format = boss_schedule_dialog_schedule_format_create(ip, ip->schedule_control); X if (!ip->appt_file) X ip->appt_file = boss_schedule_dialog_appt_file_create(ip, ip->schedule_control); X if (!ip->schedule_accept) X ip->schedule_accept = boss_schedule_dialog_schedule_accept_create(ip, ip->schedule_control); X return ip; X} X X/* X * Create object `schedule_dialog' in the specified instance. X X */ XXv_opaque Xboss_schedule_dialog_schedule_dialog_create(ip, owner) X caddr_t ip; X Xv_opaque owner; X{ X Xv_opaque obj; X X obj = xv_create(owner, FRAME_CMD, X XV_KEY_DATA, INSTANCE, ip, X XV_WIDTH, 398, X XV_HEIGHT, 140, X XV_LABEL, "Boss: Schedule Appointments", X XV_SHOW, FALSE, X FRAME_SHOW_FOOTER, FALSE, X FRAME_SHOW_RESIZE_CORNER, FALSE, X FRAME_CMD_PUSHPIN_IN, FALSE, X NULL); X xv_set(xv_get(obj, FRAME_CMD_PANEL), WIN_SHOW, FALSE, NULL); X return obj; X} X X/* X * Create object `schedule_control' in the specified instance. X X */ XXv_opaque Xboss_schedule_dialog_schedule_control_create(ip, owner) X caddr_t ip; X Xv_opaque owner; X{ X Xv_opaque obj; X X obj = xv_create(owner, PANEL, X XV_KEY_DATA, INSTANCE, ip, X XV_HELP_DATA, "boss:schedule_control", X XV_X, 0, X XV_Y, 0, X XV_WIDTH, WIN_EXTEND_TO_EDGE, X XV_HEIGHT, WIN_EXTEND_TO_EDGE, X WIN_BORDER, FALSE, X NULL); X return obj; X} X X/* X * Create object `schedule_format' in the specified instance. X X */ XXv_opaque Xboss_schedule_dialog_schedule_format_create(ip, owner) X caddr_t ip; X Xv_opaque owner; X{ X extern int schedule_notify(); X Xv_opaque obj; X X obj = xv_create(owner, PANEL_CHOICE, X XV_KEY_DATA, INSTANCE, ip, X XV_HELP_DATA, "boss:schedule_format", X XV_X, 61, X XV_Y, 14, X XV_WIDTH, 254, X XV_HEIGHT, 45, X PANEL_VALUE_X, 143, X PANEL_VALUE_Y, 14, X PANEL_LAYOUT, PANEL_HORIZONTAL, X PANEL_CHOICE_NCOLS, 1, X PANEL_LABEL_STRING, "Convert to:", X PANEL_NOTIFY_PROC, schedule_notify, X PANEL_CHOICE_STRINGS, X "calentool format", X "Calendar Manager format", X 0, X NULL); X return obj; X} X X/* X * Create object `appt_file' in the specified instance. X X */ XXv_opaque Xboss_schedule_dialog_appt_file_create(ip, owner) X caddr_t ip; X Xv_opaque owner; X{ X extern Panel_setting filename_completion(); X Xv_opaque obj; X X obj = xv_create(owner, PANEL_TEXT, X XV_KEY_DATA, INSTANCE, ip, X XV_HELP_DATA, "boss:appt_file", X XV_X, 14, X XV_Y, 64, X XV_WIDTH, 369, X XV_HEIGHT, 15, X PANEL_LABEL_STRING, "Appointment file:", X PANEL_VALUE_X, 143, X PANEL_VALUE_Y, 64, X PANEL_LAYOUT, PANEL_HORIZONTAL, X PANEL_VALUE_DISPLAY_LENGTH, 30, X PANEL_VALUE_STORED_LENGTH, 256, X PANEL_READ_ONLY, FALSE, X PANEL_NOTIFY_PROC, filename_completion, X NULL); X return obj; X} X X/* X * Create object `schedule_accept' in the specified instance. X X */ XXv_opaque Xboss_schedule_dialog_schedule_accept_create(ip, owner) X caddr_t ip; X Xv_opaque owner; X{ X extern void accept_schedule(); X Xv_opaque obj; X X obj = xv_create(owner, PANEL_BUTTON, X XV_KEY_DATA, INSTANCE, ip, X XV_HELP_DATA, "boss:schedule_accept", X XV_X, 162, X XV_Y, 100, X XV_WIDTH, 73, X XV_HEIGHT, 20, X PANEL_LABEL_STRING, "Schedule", X PANEL_NOTIFY_PROC, accept_schedule, X NULL); X return obj; X} X END_OF_FILE if test 33639 -ne `wc -c <'boss_ui.c'`; then echo shar: \"'boss_ui.c'\" unpacked with wrong size! fi # end of 'boss_ui.c' fi echo shar: End of archive 6 \(of 6\). cp /dev/null ark6isdone MISSING="" for I in 1 2 3 4 5 6 ; do if test ! -f ark${I}isdone ; then MISSING="${MISSING} ${I}" fi done if test "${MISSING}" = "" ; then echo You have unpacked all 6 archives. rm -f ark[1-9]isdone else echo You still need to unpack the following archives: echo " " ${MISSING} fi ## End of shell archive. exit 0 dan ---------------------------------------------------- O'Reilly && Associates argv@sun.com / argv@ora.com Opinions expressed reflect those of the author only.