Go Back   RunUO - Ultima Online Emulation > Developer's Corner > Programming > C#

C# C# Discussion

Reply
 
Thread Tools Display Modes
Old 09-02-2007, 03:16 PM   #1 (permalink)
Forum Expert
 
MalGanis's Avatar
 
Join Date: Dec 2005
Location: Slovenia
Age: 23
Posts: 306
Send a message via MSN to MalGanis
Default DirectX and C#

So im TabPage form and within that a Panel form. DirectX is binded with that panel. But im having some issues:
  • If i draw something in that panel with directX, when a TabPage opens/is selected/, it is blank, but if i resize (maximize, minimize,..) main window drawn stiff shows. I suspect Invalidate function is somehow overwriting directx.
  • If the image on directX is bigger than the panel, page itself it wont show scroll bars. I've tried setting propertie Width, Height of the panel or page but it wont work (panel has dock set to fill)

Any ideas?
__________________
A lawyer with a briefcase can steal more than a thousand men with guns.


Do NOT PM me asking if I will script for your shard or send you files or anything else along those lines.
MalGanis is offline   Reply With Quote
Old 09-03-2007, 06:11 AM   #2 (permalink)
Forum Expert
 
MalGanis's Avatar
 
Join Date: Dec 2005
Location: Slovenia
Age: 23
Posts: 306
Send a message via MSN to MalGanis
Default

Figured part of the first issue. I had to invalidate PageTab after paint and set its style in ctor:

Code:
SetStyle( ControlStyles.AllPaintingInWmPaint, true );
If true, the control ignores the window message WM_ERASEBKGND to reduce flicker. Now when i open a new tab it shows correctly, but if i change to another tab it still goes blank.
__________________
A lawyer with a briefcase can steal more than a thousand men with guns.


Do NOT PM me asking if I will script for your shard or send you files or anything else along those lines.

Last edited by MalGanis; 09-03-2007 at 06:14 AM.
MalGanis is offline   Reply With Quote
Reply

Bookmarks


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off



Powered by vBulletin® Version 3.7.0
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
SEO by vBSEO 3.2.0 RC5