Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
CODE PROJECT For Those Who Code
  • Home
  • Articles
  • FAQ
Community
M

Mary Chennai

@Mary Chennai
About
Posts
8
Topics
7
Shares
0
Groups
0
Followers
0
Following
0

Posts

Recent Best Controversial

  • Rotated text using Drawtext
    M Mary Chennai

    Yes I tried using DT_CALCRECT. But that isn't giving me a rotated rectangle.

    C / C++ / MFC help question

  • Rotated text using Drawtext
    M Mary Chennai

    Hi, I have used the code below to draw rotated text using DrawText. //Draw rotated text double Escapement = -401; CString str = "Hello World"; CFont newFont; newFont.CreateFont(24, 0, Escapement, Escapement, 0, 0, 0, 0, 0, 0, 0, 0, 0, "Arial"); CFont* pFont = pDC->SelectObject(&newFont); // draw the text CSize TextSize = pDC->GetTextExtent(str); CRect rect(0,0,TextSize.cx, TextSize.cy); pDC->DrawText(str, str.GetLength(), rect, DT_CENTER); Text is diplayed fine for non-rotated text. But for rotated text(ie, with Escapemnt != 0), the text appears to be clipped or sometimes not displayed at all. This is because the rect value is too restrictive for rotated text. Please can someone help me to deduce the rect value correctly for rotated texts? Regards Mary

    C / C++ / MFC help question

  • How to display vertical text using DrawText
    M Mary Chennai

    Hi, CDC* pDc = GetDC(); CSize cSize = pDc->GetTextExtent( "1", 1 ); CRect cRect ( 0, iPadding, cSize.cx, cSize.cy ); pDc->DrawText( "1", 1, &cRect , DT_CENTER|DT_VCENTER|DT_NOCLIP ); The above code displays the text "1" horizontally in cRect . To display the text vertically, i did as follows: CFont newFont; newFont.CreateFont(24, 0, 900, 900, 0, 0, 0, 0, 0, 0, 0, 0, 0, "Arial"); CFont* pFont = pDC->SelectObject(&newFont); pDC->DrawText("1", 1, &cRect, DT_CENTER|DT_VCENTER|DT_NOCLIP); pDC->SelectObject(pFont); newFont.DeleteObject(); But in this case, I couldnt get any text displayed. Please can someone help me to get the text displayed vertically. How should cRect be manipulated to draw the text vertically?

    Mary

    C / C++ / MFC help tutorial question

  • How to interact between C# and VC++ applications
    M Mary Chennai

    I have a VC++ application(say MathApp) that does some mathematical calculations using some U/I inputs, and gives the results. I have a C# application(say ManagedApp) that wants to interact with MathApp. ManangedApp has to pass the inputs to MathApp, MathApp should perform the calculations, and give back the results to ManagedApp. Can someone suggest different ways to accomplish the above task?

    Managed C++/CLI csharp c++ tutorial question

  • System.IO.FileLoadException with /clr
    M Mary Chennai

    Hi, I am currently converting my VC++ project to mixed mode by enabling /clr. But i am getting a 'System.IO.FileLoadException' in DeBug and not in Release mode, with the following information: An unhandled exception of type 'System.IO.FileLoadException' occurred in Unknown Module. Additional information: Could not load file or assembly 'MyProj, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null' or one of its dependencies. Could not find or load a type. (Exception from HRESULT: 0x80131522) Please could someone help me to resolve this.... Regards RMR

    Managed C++/CLI announcement c++ dotnet debugging help

  • LNK2020: unresolved token, with /clr
    M Mary Chennai

    Hi, When i am trying to build my VC++ exe using /clr option, i am getting the following Link Error: StdAfx.obj : error LNK2020: unresolved token (0A001984)...... Please could someone suggest me how to resolve this error? Regards Rinnu

    Managed C++/CLI c++ dotnet help tutorial question

  • LNK2020: unresolved token, with /clr
    M Mary Chennai

    Hi, When i am trying to build my C++ exe using /clr option, i am getting the following Link Error: StdAfx.obj : error LNK2020: unresolved token (0A001984)...... Please could someone suggest me how to resolve this error? Regards Rinnu

    C / C++ / MFC c++ dotnet help tutorial question

  • try-catch handling
    M Mary Chennai

    I have a try-catch block as follows try { A(); } catch(...) { } When i was working with Visual C++ 6.0, any null pointer accessed within function A was caught by the above catch. But now after VS2005 conversion, the same catch doesn't handles null pointer access, and the program crashes. Please suggest on the Project Setting to be changed for this to work.

    C / C++ / MFC c++
  • Login

  • Don't have an account? Register

  • Login or register to search.
  • First post
    Last post
0
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups