Classes | Defines | Typedefs | Functions | Variables

AbiGeneric.h File Reference

#include "ut_assert.h"
#include "ut_debugmsg.h"
#include "ut_path.h"
#include "ut_sleep.h"
#include "ut_process.h"
#include "xap_App.h"
#include "xap_DialogFactory.h"
#include "xap_Dlg_FileOpenSaveAs.h"
#include "xap_Frame.h"
#include "xap_Menu_Layouts.h"
#include "xap_Module.h"
#include "xap_Prefs.h"
#include "ap_Dialog_Id.h"
#include "ap_Menu_Id.h"
#include "ev_EditMethod.h"
#include "ev_Menu.h"
#include "ev_Menu_Actions.h"
#include "ev_Menu_Labels.h"
#include "ev_Menu_Layouts.h"
#include "fg_Graphic.h"
#include "fl_BlockLayout.h"
#include "fp_Run.h"
#include "fv_View.h"
#include "ie_imp.h"
#include "ie_impGraphic.h"
#include "ie_exp.h"
#include "ie_types.h"
#include <sys/types.h>
#include <sys/stat.h>

Go to the source code of this file.

Classes

struct  AbiMenuOptions

Defines

#define ABI_PLUGIN_NAME   AbiPlugin
#define ABI_PLUGIN_SOURCE   __FILE__
#define ABI_PLUGIN_mk2str(x)   # x
#define ABI_PLUGIN_mkstr(x)   ABI_PLUGIN_mk2str(x)
#define ABI_PLUGIN_glue(a, b)   a ## b
#define ABI_PLUGIN_xglue(a, b)   ABI_PLUGIN_glue(a,b)
#define ABI_PLUGIN_METHODNAME(a)   ABI_PLUGIN_xglue(ABI_PLUGIN_NAME,a)
#define ABI_PLUGIN_SCHEME   ABI_PLUGIN_xglue(_,ABI_PLUGIN_xglue(ABI_PLUGIN_NAME,_))
#define ABI_PLUGIN_SCHEME_NAME   ABI_PLUGIN_mkstr(ABI_PLUGIN_SCHEME)
#define ABI_PLUGIN_METHOD(m)   ABI_PLUGIN_METHODNAME(_PluginCallback_##m)
#define ABI_PLUGIN_METHOD_STR(m)   ABI_PLUGIN_mkstr(ABI_PLUGIN_METHOD(m))
#define DECLARE_ABI_PLUGIN_METHOD(m)   bool ABI_PLUGIN_METHOD(m)(AV_View* v, EV_EditMethodCallData *d)
#define ABI_GRAYABLE_MENUITEM(m)   ABI_PLUGIN_METHODNAME(_MenuGrayState_##m)
#define ABI_GRAYABLE_MENUITEM_PROTOTYPE(m)   EV_Menu_ItemState ABI_GRAYABLE_MENUITEM(m)(AV_View * pAV_View, XAP_Menu_Id id)
#define DECLARE_ABI_GRAYABLE_MENUITEM(m, boolFunc)
#define ABI_TOGGLEABLE_MENUITEM(m)   ABI_PLUGIN_METHODNAME(_MenuToggleState_##m)
#define ABI_TOGGLEABLE_MENUITEM_PROTOTYPE(m)   EV_Menu_ItemState ABI_TOGGLEABLE_MENUITEM(m)(AV_View * pAV_View, XAP_Menu_Id id)
#define DECLARE_ABI_TOGGLEABLE_MENUITEM(m, boolFunc)
#define lockGUI(d)   plugin_imp_lockGUI(d)
#define unlockGUI(d)   plugin_imp_unlockGUI(d)

Typedefs

typedef struct AbiMenuOptions AbiMenuOptions

Functions

ABI_FAR_CALL int abi_plugin_register (XAP_ModuleInfo *mi)
 Register the OpenDocument plugin.
ABI_FAR_CALL int abi_plugin_unregister (XAP_ModuleInfo *mi)
 Unregister the OpenDocument plugin.
ABI_FAR_CALL int abi_plugin_supports_version (UT_uint32 major, UT_uint32 minor, UT_uint32 release)
UT_Error addToMenus (AbiMenuOptions amo[], UT_uint32 num_menuitems, XAP_Menu_Id prevMM, XAP_Menu_Id prevCM)
UT_Error removeFromMenus (const AbiMenuOptions amo[], UT_uint32 num_menuitems)
bool getFileName (std::string &szFile, XAP_Frame *pFrame, XAP_Dialog_Id id, const char **szDescList, const char **szSuffixList, int *ft)
bool isImageSelected (void)
void plugin_imp_lockGUI (EV_EditMethodCallData *d)
void plugin_imp_unlockGUI (EV_EditMethodCallData *d)
XAP_ModuleInfogetModuleInfo (void)
bool doRegistration (void)
void doUnregistration (void)

Variables

XAP_Prefsprefs
XAP_PrefsSchemeprefsScheme
const gchar * szAbiPluginSchemeName

Define Documentation

#define ABI_GRAYABLE_MENUITEM (   m  )     ABI_PLUGIN_METHODNAME(_MenuGrayState_##m)
#define ABI_GRAYABLE_MENUITEM_PROTOTYPE (   m  )     EV_Menu_ItemState ABI_GRAYABLE_MENUITEM(m)(AV_View * pAV_View, XAP_Menu_Id id)
#define ABI_PLUGIN_glue (   a,
  b 
)    a ## b
#define ABI_PLUGIN_METHOD (   m  )     ABI_PLUGIN_METHODNAME(_PluginCallback_##m)
#define ABI_PLUGIN_METHOD_STR (   m  )     ABI_PLUGIN_mkstr(ABI_PLUGIN_METHOD(m))
#define ABI_PLUGIN_METHODNAME (   a  )     ABI_PLUGIN_xglue(ABI_PLUGIN_NAME,a)
#define ABI_PLUGIN_mk2str (   x  )     # x
#define ABI_PLUGIN_mkstr (   x  )     ABI_PLUGIN_mk2str(x)
#define ABI_PLUGIN_NAME   AbiPlugin
#define ABI_PLUGIN_SCHEME   ABI_PLUGIN_xglue(_,ABI_PLUGIN_xglue(ABI_PLUGIN_NAME,_))
#define ABI_PLUGIN_SCHEME_NAME   ABI_PLUGIN_mkstr(ABI_PLUGIN_SCHEME)
#define ABI_PLUGIN_SOURCE   __FILE__
#define ABI_PLUGIN_xglue (   a,
  b 
)    ABI_PLUGIN_glue(a,b)
#define ABI_TOGGLEABLE_MENUITEM (   m  )     ABI_PLUGIN_METHODNAME(_MenuToggleState_##m)
#define ABI_TOGGLEABLE_MENUITEM_PROTOTYPE (   m  )     EV_Menu_ItemState ABI_TOGGLEABLE_MENUITEM(m)(AV_View * pAV_View, XAP_Menu_Id id)
#define DECLARE_ABI_GRAYABLE_MENUITEM (   m,
  boolFunc 
)
Value:
ABI_GRAYABLE_MENUITEM_PROTOTYPE(m) \
{ \
    UT_UNUSED(pAV_View); \
    UT_UNUSED(id); \
    if (boolFunc()) \
        return EV_MIS_ZERO; \
    else \
        return EV_MIS_Gray; \
}
#define DECLARE_ABI_PLUGIN_METHOD (   m  )     bool ABI_PLUGIN_METHOD(m)(AV_View* v, EV_EditMethodCallData *d)
#define DECLARE_ABI_TOGGLEABLE_MENUITEM (   m,
  boolFunc 
)
Value:
ABI_TOGGLEABLE_MENUITEM_PROTOTYPE(m) \
{ \
    if (boolFunc()) \
        return EV_MIS_ZERO; \
    else \
        return EV_MIS_Toggled; \
}
#define lockGUI (   d  )     plugin_imp_lockGUI(d)

Referenced by Defun1().

#define unlockGUI (   d  )     plugin_imp_unlockGUI(d)

Referenced by Defun1().


Typedef Documentation


Function Documentation

ABI_FAR_CALL int abi_plugin_register ( XAP_ModuleInfo mi  ) 

Register the OpenDocument plugin.

References ABI_CMD_CONTEXT_TYPE, AbiCommand_registerMethod(), AbiGimp_addToMenus(), AbiGOffice_addToMenus(), AbiMathView_addToMenus(), AbiTest_registerMethod(), XAP_App::addListener(), AiksaurusABI_addToMenus(), XAP_ModuleInfo::author, BabelFish_addToMenus(), GR_GOChartManager::buildContextualMenu(), connection_pool, conversion_program, XAP_ModuleInfo::desc, doRegistration(), FREEP, FreeTranslation_addToMenus(), Garble_registerMethod(), gchar, GDA_addToMenus(), GDict_addToMenus(), XAP_App::getAbiSuiteAppDir(), XAP_App::getApp(), AbiCollabSessionManager::getManager(), getModuleInfo(), XAP_App::getPrefs(), XAP_App::getUserPrivateDirectory(), Google_addToMenus(), GR_GOComponentManager::GR_GOComponentManager(), LoadBindings_registerMethod(), LoadKeybindings(), AbiCollabSessionManager::loadProfile(), mime_types, XAP_ModuleInfo::name, Ots_addToMenus(), pdf_conversion_programs, PLUGIN_NAME, PLUGIN_TEXT, PLUGIN_WORD, Presentation_registerMethod(), progExists(), register_mime_cb(), AbiCollabSessionManager::registerAccountHandlers(), AbiCollabSessionManager::registerDialogs(), XAP_App::registerEmbeddable(), IE_Exp::registerExporter(), IE_ImpGraphic::registerImporter(), IE_Imp::registerImporter(), s_abicollab_add_menus(), AbiGrammar::setID(), AP_Win32Dialog_EpubExportOptions::setInstance(), URLDict_addToMenus(), XAP_ModuleInfo::usage, UT_ASSERT, UT_DEBUGMSG, UT_go_filename_to_uri(), UT_return_val_if_fail, UT_UTF8String::utf8_str(), XAP_ModuleInfo::version, and Wikipedia_addToMenus().

ABI_FAR_CALL int abi_plugin_supports_version ( UT_uint32  major,
UT_uint32  minor,
UT_uint32  release 
)

References isCurrentAbiVersion, and UT_UNUSED.

ABI_FAR_CALL int abi_plugin_unregister ( XAP_ModuleInfo mi  ) 
UT_Error addToMenus ( AbiMenuOptions  amo[],
UT_uint32  num_menuitems,
XAP_Menu_Id  prevMM,
XAP_Menu_Id  prevCM 
)
bool doRegistration ( void   ) 
void doUnregistration ( void   ) 

References NUM_MENUITEMS, and removeFromMenus().

Referenced by abi_plugin_unregister().

bool getFileName ( std::string &  szFile,
XAP_Frame pFrame,
XAP_Dialog_Id  id,
const char **  szDescList,
const char **  szSuffixList,
int *  ft 
)
XAP_ModuleInfo* getModuleInfo ( void   ) 

Referenced by abi_plugin_register().

bool isImageSelected ( void   ) 
void plugin_imp_lockGUI ( EV_EditMethodCallData d  ) 
void plugin_imp_unlockGUI ( EV_EditMethodCallData d  ) 
UT_Error removeFromMenus ( const AbiMenuOptions  amo[],
UT_uint32  num_menuitems 
)

Variable Documentation

const gchar* szAbiPluginSchemeName

Referenced by doRegistration().