home *** CD-ROM | disk | FTP | other *** search
/ chilidog.highland.cc.ks.us / chilidog.highland.cc.ks.us.zip / chilidog.highland.cc.ks.us / backup / bradford.20120305.etc.tar.gz / bradford.20120305.etc.tar / etc / skel / .xcoralrc < prev    next >
Text File  |  1995-11-30  |  8KB  |  266 lines

  1. /* ########################################################################
  2.    
  3.             SMAC FILE USED BY XCORAL EDITOR
  4.    
  5.    File: xcoralrc.lf
  6.    Path: /home/fournigault/c/X11/xcoral-2.33/SmacLib/xcoralrc.lf
  7.    Description: 
  8.    Created: Sun Aug  7 14:52:32 MET 1994
  9.    Author: Thierry Emery
  10.    Modified: Fri Feb 17 15:38:00 MET 1995
  11.    Last maintained by: Lionel Fournigault
  12.    
  13.    RCS $Revision$ $State$
  14.    
  15.    
  16.    ########################################################################
  17.    
  18.    Note: initialization file for Xcoral
  19.    
  20.    ########################################################################
  21.    
  22.    Copyright (c) : Thierry Emery
  23.    
  24.    This program is free software; you can redistribute it and/or modify
  25.    it under the terms of the GNU General Public License as published by
  26.    the Free Software Foundation; either version 2, or (at your option)
  27.    any later version.
  28.    
  29.    This program is distributed in the hope that it will be useful,
  30.    but WITHOUT ANY WARRANTY; without even the implied warranty of
  31.    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  32.    GNU General Public License for more details.
  33.    
  34.    You should have received a copy of the GNU General Public License
  35.    along with this program; if not, write to the Free Software
  36.    Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  37.    
  38.    ######################################################################## */
  39.  
  40.  
  41. /* -------------------------------------------------------------------------
  42.    load standard libraries
  43.    ------------------------------------------------------------------------- */
  44.  
  45. {
  46.   /* general SMAC programmer and XCORAL user utilities */
  47.   load_file("utilities.sc");
  48.   
  49.   /* C and C++ mode, auto indent, reindent, indent region etc */
  50.   load_file("mode.sc" );
  51.  
  52.   /* provide class method and function profile */
  53.   load_file("head.sc");
  54.   
  55.   /* extract logical pathname from automount pathname */
  56.   load_file("hack-filename.sc");
  57.  
  58.   /* command shell utilities, grep make user interface */
  59.   load_file("cmd.sc" );
  60.   
  61.   /* for us frenchies */
  62.   load_file("french.sc");
  63.  
  64.   /* SMAC functions writer and/or user help */
  65.   load_file("describe.sc");
  66.   
  67.   /* extensions of C and C++ modes */
  68.   load_file("mode-ext.sc");
  69.   
  70.   /* mouse customization */
  71.   load_file("mouse.sc");
  72.   
  73.   /* C C++ comments facilities */
  74.   load_file("comments.sc");
  75.   
  76.   /* file title and custom organization title */
  77.   load_file("title.sc");
  78.   
  79.   /* save file utilities */
  80.   load_file("save.sc");
  81.   
  82.   /* global set key utilities */
  83.   load_file("keydef-ext.sc");
  84.   
  85.   /* word completion */
  86.   load_file("complete-word.sc");
  87.   
  88.   /* window-utilities */
  89.   load_file("window-utilities.sc");
  90.   
  91.   /* compare two windows */
  92.   load_file("compare-win.sc");
  93.  
  94.   /* latex indent */
  95.   load_file("latex.sc");
  96.  
  97.   /* color region buffer */
  98.   load_file("color.sc");
  99.  
  100.   /* edit directory */
  101.   load_file("edir.sc");
  102.  
  103.   /* rcs interface */
  104.   load_file("rcs.sc");
  105.   
  106.   /* Version control */
  107.   load_file("version.sc");
  108.   
  109.   /* Latex utilities */
  110.   load_file("latex-macros.sc");
  111.   
  112.   /* Misc utilities */
  113.   load_file("misc-commands.sc");
  114.  
  115.  /* html utilities */
  116.   load_file("html.sc");
  117. }
  118.  
  119. /* -------------------------------------------------------------------------
  120.    define fonts
  121.    ------------------------------------------------------------------------- */
  122.  
  123. {
  124.   set_mode_font("default",
  125.           "-adobe-courier-medium-r-normal--14-140-75-75-m-90-iso8859-1");
  126.   set_mode_font("C-mode",
  127.           "-adobe-courier-medium-r-normal--14-140-75-75-m-90-iso8859-1");
  128.   set_mode_font("C++mode",
  129.           "-adobe-courier-medium-r-normal--14-140-75-75-m-90-iso8859-1");
  130.   set_mode_font("Latex",
  131.           "-adobe-courier-medium-r-normal--14-140-75-75-m-90-iso8859-1");
  132.   set_mode_font("Html",
  133.           "-adobe-courier-medium-r-normal--14-140-75-75-m-90-iso8859-1");
  134.   set_mode_font("Ada",
  135.           "-adobe-courier-medium-r-normal--14-140-75-75-m-90-iso8859-1");
  136.   set_mode_font("Perl",
  137.           "-adobe-courier-medium-r-normal--14-140-75-75-m-90-iso8859-1");
  138.   set_mode_font("Fortran",
  139.           "-adobe-courier-medium-r-normal--14-140-75-75-m-90-iso8859-1");
  140.   set_mode_font("shell",
  141.           "-adobe-courier-medium-r-normal--14-140-75-75-m-90-iso8859-1");
  142.   set_mode_font("Shell",
  143.           "-adobe-courier-medium-r-normal--14-140-75-75-m-90-iso8859-1");
  144.   set_mode_font ("french",
  145.           "-adobe-courier-medium-r-normal--14-140-75-75-m-90-iso8859-1");
  146. }
  147.  
  148. /* -------------------------------------------------------------------------
  149.    define suffixes
  150.    ------------------------------------------------------------------------- */
  151.  
  152. {
  153.   set_mode_suffixes("C++mode",".c .cc .h .sc");
  154.   set_mode_suffixes("C-mode",".c .h .sc .xcoralrc");
  155.   set_mode_suffixes("Latex",".tex .latex .sty");
  156.   set_mode_suffixes("Html",".html");
  157.   set_mode_suffixes("Perl",".pl");
  158.   set_mode_suffixes("Fortran",".f");
  159.   set_mode_suffixes("Ada",".a");
  160.   
  161.   set_mode_suffixes("french",".txt .texte");
  162. }
  163.  
  164. /* -------------------------------------------------------------------------
  165.    define modes on which global_key_def operates
  166.    ------------------------------------------------------------------------- */
  167.  
  168. {
  169.   globalize_mode("default");
  170.   globalize_mode("C-mode");
  171.   globalize_mode("C++mode");
  172.   globalize_mode("Latex");
  173.   globalize_mode("Html");
  174.   globalize_mode("Perl");
  175.   globalize_mode("Ada");
  176.   globalize_mode("Fortran");
  177.   globalize_mode("shell");
  178.   globalize_mode("french");
  179.   globalize_mode("Shell");
  180. }
  181.  
  182. /* -------------------------------------------------------------------------
  183.    define keys
  184.    ------------------------------------------------------------------------- */
  185.  
  186. {
  187.   global_key_def("^xt", "transpose_chars");
  188.   global_key_def("^xy", "transpose_forms");
  189.   global_key_def("^[\\", "delete_line_blanks");
  190.   global_key_def("^[ ",  "just_one_blank");
  191.   global_key_def("^[k",  "delete_to_beginning_of_line");
  192.   global_key_def("^xc",  "center_line");
  193.   global_key_def("^[m", "recenter");
  194.   
  195.   global_key_def("^x#", "sharp_comment");
  196.   global_key_def("^x+", "plus_comment");
  197.   global_key_def("^x=", "equal_comment");
  198.   global_key_def("^x-", "minus_comment");
  199.   global_key_def("^x%", "percent_comment");
  200.   
  201.   global_key_def("^xz", "update_title_and_save_file");
  202.   global_key_def("^xs", "update_title_backup_and_save_file");
  203.   
  204.   global_key_def("^[/", "complete_word");
  205.   
  206.   global_key_def("^xC", "CompareAgain");
  207.   
  208.   global_key_def("^xg", "go_next");
  209.  
  210.   global_key_def("^xa", "color_buffer");
  211.   global_key_def("^xr", "color_region");
  212.   
  213.   global_key_def("^xd", "edir");
  214.   key_def("Edir", "^xd", "edir");
  215.  
  216.   key_def("Shell", "^[b", "backward_c_form");
  217.   key_def("Shell", "^[f", "forward_c_form");
  218.   key_def("Shell", "^[d", "delete_next_c_form");
  219.   key_def("Shell", "^[\b", "delete_previous_c_form");
  220.   key_def("Shell", "^[\177", "delete_previous_c_form"); /* esc delete */
  221.   key_def("Shell", "^x^c", "quit_shell");
  222.  
  223. }
  224.  
  225. /* --------------------------------------------------------------------------------
  226.    French accents in Latex mode.
  227.    -------------------------------------------------------------------------------- */
  228. {
  229.     key_def("Latex", "'", "french_accent");
  230.     key_def("Latex", "`", "french_accent");
  231.     key_def("Latex", "^^", "french_accent");
  232.     key_def("Latex", "\"", "french_accent");
  233. }
  234.  
  235. /* --------------------------------------------------------------------------------
  236.    User commands: call by Users commands item in Misc Menu.
  237.    -------------------------------------------------------------------------------- */
  238. user_commands()
  239. {
  240. /****
  241.     char *str;
  242.     int win = current_window();
  243.  
  244.     clear_list();
  245.     add_list_item("User smac function 1");
  246.     add_list_item("User smac function 2");
  247.     add_list_item("User smac function 3");
  248.  
  249.     str = select_from_list("User commands");
  250.     redisplay();
  251.     select_window(win);
  252.     
  253.     if(str==0 || strlen(str) < 2) {
  254.     return;
  255.     }
  256.     
  257.     if (strcmp(str,"User smac function 1")==0) {
  258.     user_smac_function_1();
  259.     return;
  260.     }
  261.     ...
  262. ****/
  263. }
  264.  
  265.  
  266.