Which OS, Joe? I tested on Vista x64, so maybe your OS does things differently?
"Joseph M. Newcomer" <newcomer@flounder.com> wrote in message
What is interesting is that I went to the place in MFC where it calls the SetWindowText
API to change the title in the main frame to correspond to the title in the active view,
and while all the characters were in the original string, I only saw 161 of them in the
title. Very weird.
joe
On Wed, 20 May 2009 23:15:35 -0500, "Scot T Brennecke" <ScotB@MVPs.spamhater.org> wrote:
Just for grins, I tested it on my Vista Entreprise x64 machine, and it was not truncated. I used:
SetTitle(_T("_________1_________2_________3_________4_________5_________6_________7")
_T("_________8_________9_________A_________B_________C_________D_________E")
_T("_________F_________G_________H_________I_________J_________K_________L") );
in my CMainFrame::PreCreateWindow method, and all 210 characters were shown.
"TOB" <TOB@discussions.microsoft.com> wrote in message
news:0328DAA9-4FCE-4E47-91B0-EBBD32828640@microsoft.com...
It does look like it is ,but I can't find out were it does it
if I call to low level function:
::SetWindowText(g_MainFrame->m_hWnd,"a234567890b234567890c234567890d234567890e234567890f234567890g234567890h234567890i234567890j234567890k234567890l234567890m234567890n234567890p234567890q234567890r234567890s234567890t234567890u234567890v234567890w234567890x234567890y234567890z234567890");
CString str;
g_MainFrame->GetWindowText(str);
then str is truncated.
"Scot T Brennecke" wrote:
Are you sure that your longer title isn't just being truncated by the drawing routines for the
title
bar? Use Spy++ to see if the window text is maintained.
"TOB" <TOB@discussions.microsoft.com> wrote in message
news:3CB03CDB-768E-405F-BBE5-136AF7BCB18E@microsoft.com...
I can't seem to have a title of more then 159 chars for the CMainFrame
But I can for a MDI window.
Can anyone explan why?
Thank you,
Tim
Joseph M. Newcomer [MVP]
email: newcomer@flounder.com
Web: http://www.flounder.com
MVP Tips: http://www.flounder.com/mvp_tips.htm