"Fossies" - the Fresh Open Source Software Archive

Member "vim-8.2.1354/src/beval.h" (2 Aug 2020, 2495 Bytes) of package /linux/misc/vim-8.2.1354.tar.gz:


As a special service "Fossies" has tried to format the requested source page into HTML format using (guessed) C and C++ source code syntax highlighting (style: standard) with prefixed line numbers and code folding option. Alternatively you can here view or download the uninterpreted source code file. For more information about "beval.h" see the Fossies "Dox" file reference documentation and the last Fossies "Diffs" side-by-side code changes report: 8.1_vs_8.2.

    1 /* vi:set ts=8 sts=4 sw=4 noet:
    2  *
    3  * VIM - Vi IMproved    by Bram Moolenaar
    4  *          Visual Workshop integration by Gordon Prieur
    5  *
    6  * Do ":help uganda"  in Vim to read copying and usage conditions.
    7  * Do ":help credits" in Vim to see a list of people who contributed.
    8  */
    9 
   10 #if !defined(BEVAL__H) && (defined(FEAT_BEVAL) || defined(PROTO))
   11 #define BEVAL__H
   12 
   13 #ifdef FEAT_GUI_GTK
   14 # ifdef USE_GTK3
   15 #  include <gtk/gtk.h>
   16 # else
   17 #  include <gtk/gtkwidget.h>
   18 # endif
   19 #else
   20 # if defined(FEAT_GUI_X11)
   21 #  include <X11/Intrinsic.h>
   22 # endif
   23 #endif
   24 
   25 typedef enum
   26 {
   27     ShS_NEUTRAL,            // nothing showing or pending
   28     ShS_PENDING,            // data requested from debugger
   29     ShS_UPDATE_PENDING,         // switching information displayed
   30     ShS_SHOWING             // the balloon is being displayed
   31 } BeState;
   32 
   33 typedef struct BalloonEvalStruct
   34 {
   35 #ifdef FEAT_BEVAL_GUI
   36 # ifdef FEAT_GUI_GTK
   37     GtkWidget       *target;    // widget we are monitoring
   38     GtkWidget       *balloonShell;
   39     GtkWidget       *balloonLabel;
   40     unsigned int    timerID;    // timer for run
   41     BeState     showState;  // tells us what's currently going on
   42     int         x;
   43     int         y;
   44     unsigned int    state;      // Button/Modifier key state
   45 # else
   46 #  if !defined(FEAT_GUI_MSWIN)
   47     Widget      target;     // widget we are monitoring
   48     Widget      balloonShell;
   49     Widget      balloonLabel;
   50     XtIntervalId    timerID;    // timer for run
   51     BeState     showState;  // tells us what's currently going on
   52     XtAppContext    appContext; // used in event handler
   53     Position        x;
   54     Position        y;
   55     Position        x_root;
   56     Position        y_root;
   57     int         state;      // Button/Modifier key state
   58 #  else
   59     HWND        target;
   60     HWND        balloon;
   61     int         x;
   62     int         y;
   63     BeState     showState;  // tells us what's currently going on
   64 #  endif
   65 # endif
   66 # if !defined(FEAT_GUI_GTK) && !defined(FEAT_GUI_MSWIN)
   67     Dimension       screen_width;   // screen width in pixels
   68     Dimension       screen_height;  // screen height in pixels
   69 # endif
   70     void        (*msgCB)(struct BalloonEvalStruct *, int);
   71     void        *clientData;    // For callback
   72 #endif
   73 
   74     int         ts;     // tabstop setting for this buffer
   75 #ifdef FEAT_VARTABS
   76     int         *vts;       // vartabstop setting for this buffer
   77 #endif
   78     char_u      *msg;       // allocated: current text
   79 #ifdef FEAT_GUI_MSWIN
   80     void        *tofree;
   81 #endif
   82 #ifdef FEAT_GUI_HAIKU
   83     int         x;
   84     int         y;
   85 #endif
   86 } BalloonEval;
   87 
   88 #define EVAL_OFFSET_X 15 // displacement of beval topleft corner from pointer
   89 #define EVAL_OFFSET_Y 10
   90 
   91 #ifdef FEAT_BEVAL_GUI
   92 # include "gui_beval.pro"
   93 #endif
   94 
   95 #endif // BEVAL__H and FEAT_BEVAL_GUI