]> git.saurik.com Git - wxWidgets.git/blobdiff - src/os2/tooltip.cpp
Source cleaning.
[wxWidgets.git] / src / os2 / tooltip.cpp
index 90254e24821cff9377068628fc8a545aff173fef..744db82fd5344f09169c31a87c0dcef11c8c352c 100644 (file)
@@ -6,7 +6,7 @@
 // Created:     10/17/99
 // RCS-ID:      $Id$
 // Copyright:   (c) David Webster
-// Licence:     wxWindows license
+// Licence:     wxWindows licence
 ///////////////////////////////////////////////////////////////////////////////
 
 // ============================================================================
@@ -56,13 +56,12 @@ void wxToolTip::Create(
 )
 {
     ULONG                           lStyle = ES_READONLY | ES_MARGIN | ES_CENTER;
-    wxColour                        vColor;
     LONG                            lColor;
     char                            zFont[128];
 
     m_hWnd = ::WinCreateWindow( HWND_DESKTOP
                                ,WC_ENTRYFIELD
-                               ,rsTip.c_str()
+                               ,(PSZ)rsTip.c_str()
                                ,lStyle
                                ,0, 0, 0, 0
                                ,NULLHANDLE
@@ -72,16 +71,16 @@ void wxToolTip::Create(
                                ,NULL
                               );
     if (!m_hWnd)
-        wxLogError("Unable to create tooltip window");
+        wxLogError(_T("Unable to create tooltip window"));
 
-    vColor.InitFromName("YELLOW");
+    wxColour                        vColor( wxT("YELLOW") );
     lColor = (LONG)vColor.GetPixel();
     ::WinSetPresParam( m_hWnd
                       ,PP_BACKGROUNDCOLOR
                       ,sizeof(LONG)
                       ,(PVOID)&lColor
                      );
-    strcpy(zFont, "10.Helv");
+    strcpy(zFont, "8.Helv");
     ::WinSetPresParam( m_hWnd
                       ,PP_FONTNAMESIZE
                       ,strlen(zFont) + 1
@@ -98,7 +97,7 @@ void wxToolTip::DisplayToolTipWindow(
     LONG                            lWidth = 0L;
     LONG                            lHeight = 0L;
 
-    lWidth = m_sText.Length() * 13;
+    lWidth = m_sText.Length() * 8;
     lHeight = 15;
     ::WinSetWindowPos( m_hWnd
                       ,HWND_TOP
@@ -125,7 +124,7 @@ void wxToolTip::SetTip(
 
     ::WinQueryWindowPos(m_hWnd, &vSwp);
     m_sText = rsTip;
-    lWidth = rsTip.Length() * 13;
+    lWidth = rsTip.Length() * 8;
     lHeight = 15;
     ::WinSetWindowPos( m_hWnd
                       ,HWND_TOP