Public Types | Public Member Functions | List of all members
ipe::IpeletHelper Class Referenceabstract

#include <ipelet.h>

Public Types

enum  {
  EOkButton , EOkCancelButtons , EYesNoCancelButtons , EDiscardCancelButtons ,

Public Member Functions

virtual ~IpeletHelper ()=0
virtual void message (const char *msg)=0
virtual int messageBox (const char *text, const char *details, int buttons)=0
virtual bool getString (const char *prompt, String &str)=0
virtual String getParameter (const char *key)=0

Detailed Description

Service provider for Ipelets.

C++ Ipelets can ask Ipe to perform various services and request information using this class.

Member Enumeration Documentation

◆ anonymous enum

anonymous enum

Constructor & Destructor Documentation

◆ ~IpeletHelper()

IpeletHelper::~IpeletHelper ( )
pure virtual

Pure virtual destructor.

Member Function Documentation

◆ message()

virtual void ipe::IpeletHelper::message ( const char *  msg)
pure virtual

Show a message in the status bar.

◆ messageBox()

virtual int ipe::IpeletHelper::messageBox ( const char *  text,
const char *  details,
int  buttons 
pure virtual

Pop up a modal message box.

The details can be null.

Choose one of EOkButton, EOkCancelButtons, EYesNoCancelButtons, EDiscardCancelButtons, ESaveDiscardCancelButtons for buttons.

Returns 1 for Ok or Yes, 0 for No, -1 for Cancel.

◆ getString()

virtual bool ipe::IpeletHelper::getString ( const char *  prompt,
String str 
pure virtual

Pop up a modal dialog asking the user to enter a string. Returns true if the user didn't cancel the dialog.

◆ getParameter()

virtual String ipe::IpeletHelper::getParameter ( const char *  key)
pure virtual

Retrieve a parameter value from a table in the Lua wrapper code. If no table has been passed, or the key is not in the table, or its value is not a string or a number, then an empty string is returned.

The documentation for this class was generated from the following files: