NCBI C Toolkit Cross Reference

C/vibrant/netscape.h


  1 /* $Id: netscape.h,v 6.1 1998/01/21 21:22:30 vakatov Exp $
  2  * Copyright (c) 1996 Netscape Communications Corporation, all rights reserved.
  3 * ===========================================================================
  4 *
  5 *                            PUBLIC DOMAIN NOTICE
  6 *               National Center for Biotechnology Information
  7 *
  8 *  This software/database is a "United States Government Work" under the
  9 *  terms of the United States Copyright Act.  It was written as part of
 10 *  the author's official duties as a United States Government employee and
 11 *  thus cannot be copyrighted.  This software/database is freely available
 12 *  to the public for use. The National Library of Medicine and the U.S.
 13 *  Government have not placed any restriction on its use or reproduction.
 14 *
 15 *  Although all reasonable efforts have been taken to ensure the accuracy
 16 *  and reliability of the software and data, the NLM and the U.S.
 17 *  Government do not and cannot warrant the performance or results that
 18 *  may be obtained by using this software or data. The NLM and the U.S.
 19 *  Government disclaim all warranties, express or implied, including
 20 *  warranties of performance, merchantability or fitness for any particular
 21 *  purpose.
 22 *
 23 *  Please cite the author in any work or product based on this material.
 24 *
 25 * ===========================================================================
 26 *
 27 * File Name:  $RCSfile: netscape.h,v $
 28 *
 29 * Author:  Sergei Shavirin
 30 *
 31 * Initial Version Creation Date: 11/08/1997
 32 *
 33 * $Revision: 6.1 $
 34 *
 35 * File Description:
 36 *        Main definitions file for Vibrant -> Netscape Index Program
 37 *        NOTE: this is actually a UNIX/X11 code only; on other platforms
 38 *              all API functions do nothing and return FALSE
 39 *
 40 *---------------------------------------------------------------------------
 41 * $Log: netscape.h,v $
 42 * Revision 6.1  1998/01/21 21:22:30  vakatov
 43 * Initial revision
 44 *
 45 *
 46 * ==========================================================================
 47 */
 48 
 49 /* Complete explanation of the interface is given at:
 50    http://home.netscape.com/newsref/std/x-remote.html */
 51 
 52 #ifndef __NETSCAPE_H__
 53 #define __NETSCAPE_H__
 54 
 55 #include <ncbistd.h>
 56 
 57 
 58 #ifdef __cplusplus
 59 extern "C" {
 60 #endif /* __cplusplus */
 61 
 62 /* Type definitions */
 63 
 64 struct NS_WindowTag;
 65 typedef struct NS_WindowTag PNTR NS_Window;
 66 typedef NS_Window PNTR NS_WindowPtr;
 67 
 68 /* External functions */
 69 
 70 /* ------------------------  NS_SendCommand  -----------------------
 71    Purpose:     Send command to the Netscape
 72    Parameters:  window - handle of Netscape Window. Will be initialized
 73                          inside function itself
 74                 cmd - command to sent to the Netscape window
 75                 url - if not NULL command will be sent to window
 76                       identified by this URL
 77                 wintag - _logical_ name of window in Netscape
 78 
 79    Returns:     TRUE on success...
 80    NOTE:        If Netscape is not loaded - it will be loaded first
 81                 no command will be sent
 82                 See list of commands in the end of this file
 83   ------------------------------------------------------------------*/
 84 extern Nlm_Boolean NS_SendCommand(NS_WindowPtr window,
 85                                   const Nlm_Char *cmd, 
 86                                   const Nlm_Char *url,
 87                                   const Nlm_Char *wintag,
 88                                   Nlm_Boolean raise);
 89 
 90 /* ------------------------  NS_OpenURL  -----------------------
 91    Purpose:     Loads a specific URL to the Netscape window
 92    Parameters:  window - ptr to handle of Netscape Window. Will be initialized
 93                          inside function itself
 94                 url - URL to load to the Netscape
 95                 wintag - _logical_ name of window in Netscape
 96 
 97    Returns:     TRUE on success...
 98    NOTE:        If Netscape is not loaded - it will be loaded first
 99                 no command will be sent
100                 Program in first call will try to find Netscape window
101                 with specified URL -if nothing present it will peak up
102                 first available and will use only this window afterwards
103   ------------------------------------------------------------------*/
104 extern Nlm_Boolean NS_OpenURL(NS_WindowPtr window, const Nlm_Char *url, 
105                               const Nlm_Char *wintag, Nlm_Boolean raise);
106 
107 
108 /* ------------------------  NS_ResetWindow  -----------------------
109    Purpose:     Force next command to reinitialize Netscape window
110    Parameters:  window - ptr to handle of Netscape Window.
111    Returns:     None
112   ------------------------------------------------------------------*/
113 extern void NS_ResetWindow(NS_Window window);
114 
115 
116 /* ------------------------  NS_ResetWindow  -----------------------
117    Purpose:     Will free Netscape window handle 
118    Parameters:  window - handle of Netscape Window.
119    Returns:     None
120   ------------------------------------------------------------------*/
121 extern void NS_WindowFree(NS_Window window);
122 
123 
124 /*-------------------------------------------------------
125      openURL ( )
126           Prompts for a URL with a dialog box.
127      openURL (URL)
128           Opens the specified document without prompting.
129      openURL (URL, new-window)
130           Create a new window displaying the the specified document.
131      openFile ( )
132           Prompts for a file with a dialog box.
133      openFile (File)
134           Opens the specified file without prompting.
135      saveAs ( )
136           Prompts for a file with a dialog box (like the menu item).
137      saveAs (Output-File)
138           Writes HTML to the specified file without prompting.
139      saveAs (Output-File, Type)
140           Writes to the specified file with the type specified - the type
141           may be HTML, Text, or PostScript.
142      mailto ( )
143           pops up the mail dialog with the To: field empty.
144      mailto (a, b, c)
145           Puts the addresses "a, b, c" in the default To: field.
146      addBookmark ( )
147           Adds the current document to the bookmark list.
148      addBookmark (URL)
149           Adds the given document to the bookmark list.
150      addBookmark (URL, Title)
151           Adds the given document to the bookmark list, with the given
152           title.
153 ----------------------------------------------------------*/
154 
155 #ifdef __cplusplus
156 }
157 #endif /* __cplusplus */
158 
159 #endif /* __NETSCAPE_H__ */
160 

source navigation ]   [ diff markup ]   [ identifier search ]   [ freetext search ]   [ file search ]  

This page was automatically generated by the LXR engine.
Visit the LXR main site for more information.