//-----------------------------------------------------------------------------
// wx.NET - tipwin.h
//
// Licensed under the wxWidgets license, see LICENSE.txt for details.
//
// $Id: TipWindow.cs,v 1.3 2007/12/08 23:21:15 harald_meyer Exp $
//-----------------------------------------------------------------------------
using System;
using System.Drawing;
using System.Runtime.InteropServices;
namespace wx{
public class TipWindow : Window
{
[DllImport("wx-c")] static extern IntPtr wxTipWindow_ctor(IntPtr parent, IntPtr text, int maxLength, int x, int y, int width, int height);
[DllImport("wx-c")] static extern IntPtr wxTipWindow_ctorNoRect(IntPtr parent, IntPtr text, int maxLength);
//[DllImport("wx-c")] static extern void wxTipWindow_SetTipWindowPtr(IntPtr self, IntPtr wxTipWindow* windowPtr);
[DllImport("wx-c")] static extern void wxTipWindow_SetBoundingRect(IntPtr self, ref Rectangle rectBound);
[DllImport("wx-c")] static extern void wxTipWindow_Close(IntPtr self);
//-----------------------------------------------------------------------------
public TipWindow(IntPtr wxObject)
: base(wxObject) { }
public TipWindow(Window parent, string text)
: this(parent, text, 100) { }
public TipWindow(Window parent, string text, int maxLength)
: this(parent, wxString.SafeNew(text), maxLength) { }
public TipWindow(Window parent, wxString text, int maxLength)
: this(wxTipWindow_ctorNoRect(Object.SafePtr(parent), Object.SafePtr( text), maxLength)) { }
public TipWindow(Window parent, string text, int maxLength, Rectangle rectBound)
: this(parent, wxString.SafeNew(text), maxLength, rectBound) { }
public TipWindow(Window parent, wxString text, int maxLength, Rectangle rectBound)
: this(wxTipWindow_ctor(Object.SafePtr(parent), Object.SafePtr(text), maxLength, rectBound.X, rectBound.Y, rectBound.Width, rectBound.Height)) { }
//-----------------------------------------------------------------------------
/*public void SetTipWindowPtr( TipWindow* windowPtr)
{
wxTipWindow_SetTipWindowPtr(wxObject, Object.SafePtr(TipWindow* windowPtr));
}*/
//-----------------------------------------------------------------------------
public Rectangle BoundingRect
{
set { wxTipWindow_SetBoundingRect(wxObject, ref value); }
}
}
}
|