Can two DCs share one GDI object (brush, pen, etc.)?

Can two device contexts (DCs) share one GDI object, such as a brush or a pen?

Answers


The documentation for SelectObject mentions that Bitmaps cannot be selected into more than one DC at a time.

Essentially this is because GDI operations can write to a bitmap, and it would be complex to manage multiple write operations at a time. However all the other GDI objects, once created (with the exception of regions - but those are always copied), are immutable, therefore have no restrictions on being selected into multiple DCs at a time.


Need Your Help

how to update a field value of a data store in google app engine using java

java google-app-engine gae-datastore

I had created a Login (Kind) in the data store. Inside the login, I created two fields username and passsword. When the user changes the password I want to update the field value inside the datasto...

About UNIX Resources Network

Original, collect and organize Developers related documents, information and materials, contains jQuery, Html, CSS, MySQL, .NET, ASP.NET, SQL, objective-c, iPhone, Ruby on Rails, C, SQL Server, Ruby, Arrays, Regex, ASP.NET MVC, WPF, XML, Ajax, DataBase, and so on.