Resubmit SetWindowTextA() patch

Mike McCormack mike at
Mon Jun 6 19:03:38 CDT 2005

Jason Campbell wrote:

> +/*
>          FIXME( "cannot set text %s of other process window %p\n", 
> debugstr_a(lpString), hwnd );
>          SetLastError( ERROR_ACCESS_DENIED );
>          return FALSE;
> +*/
> +       FIXME( "not allowed by MSDN but some apps programmed this way" );
>      }
>      return (BOOL)SendMessageA( hwnd, WM_SETTEXT, 0, (LPARAM)lpString );
>  }

Hi Jason,

I think the fixme is not Wine enforcing a limitation imposed by MSDN, 
but preventing a problem from occuring because it's not supported 
properly by Wine, so though the above may work for a few applications, 
it doesn't seem like a solution that will work for everything.

To do this the "right way" you'd need to write a test case to show what 
happens on Windows when somebody tries to set the title of another window.

If this now works, you shouldn't just comment out the code in the if() 
statement, but instead remove the if() statement and FIXME all together. 
  I suspect that it won't work correctly if the window has a visible 
caption bar.


More information about the wine-devel mailing list