Mailing Lists: Apple Mailing Lists

Image of Mac OS face in stamp
 
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Dynamic Tabs Redraw Issue



I've no idea if this will work but there's a problem with tab controls created from IB in 10.2 where you get artifacts. The solution is to make sure that you save the NIB file with the first tab selected. It may be worth selecting the first tab before adding or removing tabs.

Jerry

On 28 Feb 2005, at 23:33, Stevo Brock wrote:

Hi David,

Thanks for the response. Unfortunately doing the hide/remove/show doesn't change things at all. I still get crud/turds/artifacts!

Code:

SetControlVisibility(controlRef, false, true);
SetControl32BitMaximum(controlRef, 2);	// was 3
SetControlVisibility(controlRef, true, true);

The tab control I'm modifying is embedded inside a user pane which is actually inside another user pane which is inside a tab. Are there settings that I need to adjust for the user panes (or events to handle) that would help?

-Stevo Brock
 Monkey Tools
 www.monkey-tools.com


On Feb 25, 2005, at 5:47 PM, David McLeod wrote:


On Feb 23, 2005, at 6:41 PM, Stevo Brock wrote:

I have a Tab control that I am adding to and removing tabs from dynamically. I'm seeing the issue on OS X 10.2.8 in a non-compositing window, where, after removing a tab, the tab control redraws itself, but doesn't completely erase all of the old tab graphics. That is, there's artifacts left on the screen to the left and right of the new tabs.

In the particular case I'm dealing with, the dynamic tab is embedded inside another tab control. By calling:

ControlRef controlRef;
::GetSuperControl(tabControlRef, &controlRef); // Get to tab contents container control
::GetSuperControl(controlRef, &controlRef); // Get to tab item control
::GetSuperControl(controlRef, &controlRef); // Get to tab control
::Draw1Control(controlRef);


Of course, the dynamic tab control could be just in a window in which there isn't this guaranteed hierarchy. It could also be in a compositing window. What is the easiest and best way to trigger a redraw of this screen space?

I don't know if it will work, but I'd be inclined to try hiding the tab control, add/remove a tab, show the tab control. Does that eliminate the artifacts?


Incidentally, the highly technical term that is often used around here for "artifacts" is "turds". Matt likes "crud".



_______________________________________________ Do not post admin requests to the list. They will be ignored. Carbon-dev mailing list (email@hidden) Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/carbon-dev/email@hidden

This email sent to email@hidden

_______________________________________________
Do not post admin requests to the list. They will be ignored.
Carbon-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/carbon-dev/email@hidden

This email sent to email@hidden


Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2007 Apple Inc. All rights reserved.