Search Results

Search found 4 results on 1 pages for 'sasikumar'.

Page 1/1 | 1 

  • Load a png resource into a CBitMap

    - by Rohit Sasikumar
    How do i load a png resource into a CBitMap? When i try this it doesnt work. CImage image; image.LoadFromResource(AfxGetInstanceHandle(), IDB_PNG1); bitmap.Attach(image.Detach()); It gives me an error resource type not found. Is there any other way to load a PNG resource?

    Read the article

  • bitmap button not displaying in 3D style

    - by Rohit Sasikumar
    Hi, I want to display on my dialog, a bitmap button. I am using the below code CImage image; hr = image.Load(_T("myimage.png")); // just change extension to load jpg bitmap.Attach(image.Detach()); m_button.ModifyStyle(0,BS_BITMAP); m_button.SetBitmap(bitmap); This way bitmap is correctly displayed on button, but the button is not displayed in 3D style as normal buttons would look. I have set owner drawn property to false, still it displaying like this. Any ideas as to what could be wrong? Thanks, Rohit

    Read the article

  • iPhone How to set a clearcolor for my custom view

    - by user355066
    Hi, I am creating a custom StyleLabel by extending the UIView, which provides a link for particular type of strings. I have successfully implemented this functionality. I am using this label in TableViewCell along with UILabel.i set UILabel & StyleLabel background color is set to clearColor. UILabel works fine, but StyleLabel shows background in blackColor. I am not sure what is the problem with the following code. Here is the drawRect method of CustomLabel class -(void) drawRect:(CGRect)rect { CGContextRef ctx = UIGraphicsGetCurrentContext(); CGContextClearRect(ctx, rect); [[UIColor clearColor] setFill]; CGContextAddRect(ctx, rect); CGContextDrawPath(ctx, kCGPathFill); [_text drawText:ctx]; } Thanks Sasikumar

    Read the article

1