Register - Login
Views: 99869300
Main - Memberlist - Active users - Calendar - Wiki - IRC Chat - Online users
Ranks - Rules/FAQ - Stats - Latest Posts - Color Chart - Smilies
05-04-22 06:41:14 PM
Jul - Computers and Technology - My window has a deformed title bar no matter what I do. New poll - New thread - New reply
Next newer thread | Next older thread
Rena
I had one (1) message in Discord deleted and proceeded to make a huge, huge mess about how it was a violation of free speech and how moderators are supposed to be spam janitors and nobody should have the right to tell me not to talk about school shootings
Level: 135


Posts: 750/5390
EXP: 29079552
For next: 255453

Since: 07-22-07

Pronouns: he/him/whatever
From: RSP Segment 6

Since last post: 343 days
Last activity: 343 days

Posted on 08-23-07 07:56:57 PM; last edit by HyperHacker on 08-23-07 07:58 PM Link | Quote
JL2 - Post #750 - 08-23-07 02:56:57 PM
Day 32, rank 7; Level 28 (3.1%)
472/15179 (116631/131338)
GPP: 233; GT: 47.772
Creating a window with only the WS_CLIPSIBLINGS (which seems to be forced) and WS_VISIBLE styles, I get this:

beans
At first the window appears with no border or title bar as normal, and doesn't show up in the taskbar. Once it loses focus, this partial title bar appears and it gets added to the taskbar. Double UTF?
(Also, blue on red + MSPaint + JPEG = utter fail.)

____________________
chungy
Member
Level: 31


Posts: 42/174
EXP: 168466
For next: 16897

Since: 08-04-07


Since last post: 14.1 years
Last activity: 13.9 years

Posted on 08-23-07 08:55:16 PM Link | Quote
so uhh, is the appropriate response "lol, windows bugs"?
Rena
I had one (1) message in Discord deleted and proceeded to make a huge, huge mess about how it was a violation of free speech and how moderators are supposed to be spam janitors and nobody should have the right to tell me not to talk about school shootings
Level: 135


Posts: 774/5390
EXP: 29079552
For next: 255453

Since: 07-22-07

Pronouns: he/him/whatever
From: RSP Segment 6

Since last post: 343 days
Last activity: 343 days

Posted on 08-24-07 09:42:27 PM Link | Quote
JL2 - Post #774 - 08-24-07 04:42:27 PM
Day 33, rank 7; Level 28 (53.6%)
8133/15179 (124292/131338)
GPP: 240; GT: 46.320
A helpful response might be better, but anyway... I found the main problem. You have to call SetWindowPos() with the SWP_FRAMECHANGED flag after switching titlebars on/off/toolwindow-style. But still, the window doesn't show up in the taskbar at first, despite what MSDN says:

WS_EX_APPWINDOW
Forces a top-level window onto the taskbar when the window is visible.
It's visible, and has this style, but doesn't show up on the taskbar until it gets focus. (In fact, it has focus when it's first created, and has to lose it and gain it again.) It stays there afterward, though. (This one probably is a Windows bug. )

[edit/bump] OK, here's another one. How do I put Unicode text in a title bar? I see if I put Chinese characters ("日本語") in a filename and open it with Notepad, they show up just fine in the taskbar and titlebar. Putting that text in a text file and saving it as Unicode, the result in a hex editor is \xFF\xFE\xE5\x65\x2C\x67\x9E\x8A. I can pass that to TextOutW() and it works fine, but passing it to SetWindowTextW() or as a parameter to WM_SETTEXT gets me question marks or gibberish.

____________________
neotransotaku
Member
wonders why OSX does not come with their version of MSPaint?
Level: 53


Posts: 5/603
EXP: 1084844
For next: 72275

Since: 08-24-07

From: The Landmark @ One Market

Since last post: 2.6 years
Last activity: 42 days

Posted on 08-25-07 06:03:22 AM Link | Quote
Could it be related to the font you are using to render the titlebar title? Unless it is font that contains unicode in it (i.e. Arial Unicode or MSGothic), something like Tahoma or Verdana is going to choke I believe.
Kles

Level: 87


Posts: 570/1947
EXP: 6312780
For next: 79994

Since: 07-23-07


Since last post: 79 days
Last activity: 7 hours

Posted on 08-25-07 08:10:30 AM Link | Quote
Originally posted by HyperHacker
I see if I put Chinese characters ("日本語")


I should delete this thread for that.

____________________
؟
chungy
Member
Level: 31


Posts: 45/174
EXP: 168466
For next: 16897

Since: 08-04-07


Since last post: 14.1 years
Last activity: 13.9 years

Posted on 08-25-07 08:15:15 AM Link | Quote
Have you tried the UTF-8 version of that? Dunno if it'll work though... 0xE6 0x97 0xA5 0xE6 0x9C 0xAC 0xE8 0xAA 0x9E

Else you might as well keep reading MSDN.
Joe
Common spammer
🍬
Level: 111


Posts: 51/3392
EXP: 14503158
For next: 365202

Since: 08-02-07

From: Pororoca

Since last post: 13 days
Last activity: 1 hour

Posted on 08-25-07 06:15:38 PM Link | Quote
Unicode? Hmm... If UTF-8 doesn't work (since that's what I would try), then try \x65\xE5\x67\x2C\x8A\x9E. If it still doesn't work, try \xFE\xFF\x65\xE5\x67\x2C\x8A\x9E.

Also:

Originally posted by Party Pooper
Originally posted by HyperHacker
I see if I put Chinese characters ("日本語")


I should delete this thread for that.

No, then I wouldn't be able to see how pointlessly difficult it is to program Windows apps.

____________________
chungy
Member
Level: 31


Posts: 47/174
EXP: 168466
For next: 16897

Since: 08-04-07


Since last post: 14.1 years
Last activity: 13.9 years

Posted on 08-25-07 07:06:01 PM Link | Quote
Originally posted by Joe
then try \x65\xE5\x67\x2C\x8A\x9E

What encoding is that? Also your second one is the same that HH tried at first.
Rena
I had one (1) message in Discord deleted and proceeded to make a huge, huge mess about how it was a violation of free speech and how moderators are supposed to be spam janitors and nobody should have the right to tell me not to talk about school shootings
Level: 135


Posts: 791/5390
EXP: 29079552
For next: 255453

Since: 07-22-07

Pronouns: he/him/whatever
From: RSP Segment 6

Since last post: 343 days
Last activity: 343 days

Posted on 08-25-07 10:18:08 PM Link | Quote
JL2 - Post #791 - 08-25-07 05:18:08 PM
Day 34, rank 7; Level 28 (93.6%)
14210/15179 (130369/131338)

GPP: 247; GT: 45.519
Originally posted by neotransotaku
Could it be related to the font you are using to render the titlebar title? Unless it is font that contains unicode in it (i.e. Arial Unicode or MSGothic), something like Tahoma or Verdana is going to choke I believe.
It's the same font every title bar uses, and Notepad is doing it fine.

Originally posted by Party Pooper
Originally posted by HyperHacker
I see if I put Chinese characters ("日本語")


I should delete this thread for that.
What? Because I wrote "Japanese" using Chinese characters?

Originally posted by chungy
Originally posted by Joe
then try \x65\xE5\x67\x2C\x8A\x9E

What encoding is that? Also your second one is the same that HH tried at first.
Except for the byte order.

Originally posted by Joe
Unicode? Hmm... If UTF-8 doesn't work (since that's what I would try), then try \x65\xE5\x67\x2C\x8A\x9E. If it still doesn't work, try \xFE\xFF\x65\xE5\x67\x2C\x8A\x9E.

Nope, both gibberish (using WM_SETTEXT) or question marks (using SetWindowTextW()). Same with UTF-8 (which Windows doesn't seem to use anywhere else).

____________________
neotransotaku
Member
wonders why OSX does not come with their version of MSPaint?
Level: 53


Posts: 6/603
EXP: 1084844
For next: 72275

Since: 08-24-07

From: The Landmark @ One Market

Since last post: 2.6 years
Last activity: 42 days

Posted on 08-26-07 01:29:23 AM Link | Quote
Originally posted by HyperHacker
Originally posted by neotransotaku
Could it be related to the font you are using to render the titlebar title? Unless it is font that contains unicode in it (i.e. Arial Unicode or MSGothic), something like Tahoma or Verdana is going to choke I believe.
It's the same font every title bar uses, and Notepad is doing it fine.


Perhaps, you need to add extra logic to switch the font to the appropriate language? On my computer, Trebuchet MS doesn't have CJK characters while MSGothic does. So, I think that is what notepad is doing, it has sometype of character detection scheme in it.
chungy
Member
Level: 31


Posts: 48/174
EXP: 168466
For next: 16897

Since: 08-04-07


Since last post: 14.1 years
Last activity: 13.9 years

Posted on 08-26-07 03:31:19 AM Link | Quote
I don't think Windows even has that feature.
Deleted User
Collection of nobodies
Posted on 08-31-07 04:29:49 PM Link | Quote
I doubt using non-latin characters is a big deal. If even Notepad can do it...

____________________


===================
[Posted by Kawa]
Next newer thread | Next older thread
Jul - Computers and Technology - My window has a deformed title bar no matter what I do. New poll - New thread - New reply


Rusted Logic

Acmlmboard - commit 47be4dc [2021-08-23]
©2000-2022 Acmlm, Xkeeper, Kaito Sinclaire, et al.

30 database queries, 4 query cache hits.
Query execution time: 0.091733 seconds
Script execution time: 0.025265 seconds
Total render time: 0.116998 seconds