Bug 2035 – D makes GUI dirty

Status
RESOLVED
Resolution
INVALID
Severity
minor
Priority
P2
Component
dmd
Product
D
Version
D2
Platform
x86
OS
Windows
Creation time
2008-04-25T12:33:38Z
Last change time
2021-03-03T12:15:27Z
Assigned to
Walter Bright
Creator
anonymous4

Attachments

IDFilenameSummaryContent-TypeSize
250testcase.zipsources and compiled executablesapplication/zip51668
251win2da.PNGscreenshot of win2da.exeimage/png9427

Comments

Comment #0 by dfj1esp02 — 2008-04-25T12:33:38Z
When I tried to build a "Hello world" Windows GUI application, main window's menu painted dirty: thin 1-pixel width line appeared under menu bar, and this line was not updating. Nothing helped. I tried various window styles, classes, I loaded menu from resources, created it manually, created dialog boxes with menu. Nothing changed, non-updating line appeared everywhere. But test dialog box in resource editor rendered just perfectly. I started to suspect dmd. I created two source codes that do the same things - one in D and one in C. I compiled C source with gcc and window rendered perfectly, D application'w window rendered dirty. I'm not shure what causes the problem.
Comment #1 by dfj1esp02 — 2008-04-25T12:36:28Z
Created attachment 250 sources and compiled executables compilation commands are gcc -Wall -pipe -mwindows win2.c -o win2gcc.exe dmd win2.d win2.def win2da.exe
Comment #2 by dfj1esp02 — 2008-04-25T12:39:50Z
Created attachment 251 screenshot of win2da.exe Dirty line under menu is easily visible and it doesn't update when another window moves above this window.
Comment #3 by benoit — 2008-04-25T13:58:32Z
There is this line and some of the controls have white background? use this linker options -L/SUBSYSTEM:windows:5
Comment #4 by dfj1esp02 — 2008-04-25T15:05:44Z
Thanks, that works! Is there some way to configure it in configuration files or in .def file?
Comment #5 by dfj1esp02 — 2008-04-25T15:12:41Z
http://www.digitalmars.com/ctg/ctgDefFiles.html#subsystem The SUBSYSTEM directive should be SUBSYSTEM WINDOWS 4.0
Comment #6 by dfj1esp02 — 2008-04-28T02:07:26Z
I think problem is actually in winsamp sample, I took .def file there.
Comment #7 by bugzilla — 2008-05-14T19:16:18Z
Comment #8 by dfj1esp02 — 2021-03-03T12:15:27Z
*** Issue 21655 has been marked as a duplicate of this issue. ***