Re: Rendering text question (context is MSWin UI Automation)

2007-01-25 Thread Boris Borcic
Chris Mellon wrote: On 1/24/07, Boris Borcic [EMAIL PROTECTED] wrote: Chris Mellon wrote: Using either win32 or wxPython you will be able to produce bitmaps directly, without needing to create a visible window. Some quick dirty wxPython code def getTextBitmap(text, font, fgcolor,

Re: Rendering text question (context is MSWin UI Automation)

2007-01-25 Thread Chris Mellon
On 1/25/07, Boris Borcic [EMAIL PROTECTED] wrote: Chris Mellon wrote: On 1/24/07, Boris Borcic [EMAIL PROTECTED] wrote: Chris Mellon wrote: Using either win32 or wxPython you will be able to produce bitmaps directly, without needing to create a visible window. Some quick dirty

Re: Rendering text question (context is MSWin UI Automation)

2007-01-25 Thread Boris Borcic
Chris Mellon wrote: On 1/25/07, Boris Borcic [EMAIL PROTECTED] wrote: Chris Mellon wrote: Some quick dirty wxPython code def getTextBitmap(text, font, fgcolor, bgcolor): dc = wx.MemoryDC() dc.SetFont(font) width, height= dc.GetTextExtent(text) bmp =

Re: Rendering text question (context is MSWin UI Automation)

2007-01-25 Thread Chris Mellon
On 1/25/07, Boris Borcic [EMAIL PROTECTED] wrote: Chris Mellon wrote: On 1/25/07, Boris Borcic [EMAIL PROTECTED] wrote: Chris Mellon wrote: Some quick dirty wxPython code def getTextBitmap(text, font, fgcolor, bgcolor): dc = wx.MemoryDC() dc.SetFont(font) width,

Re: Rendering text question (context is MSWin UI Automation)

2007-01-25 Thread Boris Borcic
Chris Mellon wrote: Maybe. In any case, color separation solves my (sub)problem : the blue layer from the wx generated model matches the green layer from the app's window, pixel for pixel (at least with antialiasing and cleartype on, while writing black on white). That's... extremely

Re: Rendering text question (context is MSWin UI Automation)

2007-01-24 Thread Boris Borcic
imageguy wrote: I was looking for ( and still am searching for) similiar functionality. Specifically I would like to be able to capture a small area of the screen (a number or a code) and convert this to text that can be used in my application. There is a windows executable version of gnu

Re: Rendering text question (context is MSWin UI Automation)

2007-01-24 Thread Boris Borcic
Chris Mellon wrote: On 1/23/07, Boris Borcic [EMAIL PROTECTED] wrote: ...A simple - with Tkinter or otherwise - way to wrap access to the MS Windows UI text rendering engine, as a function that would return a picture of rendered text, given a string, a font, a size and colors ? ...

Re: Rendering text question (context is MSWin UI Automation)

2007-01-24 Thread Boris Borcic
Chris Mellon wrote: Using either win32 or wxPython you will be able to produce bitmaps directly, without needing to create a visible window. Some quick dirty wxPython code def getTextBitmap(text, font, fgcolor, bgcolor): dc = wx.MemoryDC() dc.SetFont(font) width,

Re: Rendering text question (context is MSWin UI Automation)

2007-01-24 Thread Chris Mellon
On 1/24/07, Boris Borcic [EMAIL PROTECTED] wrote: Chris Mellon wrote: Using either win32 or wxPython you will be able to produce bitmaps directly, without needing to create a visible window. Some quick dirty wxPython code def getTextBitmap(text, font, fgcolor, bgcolor): dc

Rendering text question (context is MSWin UI Automation)

2007-01-23 Thread Boris Borcic
Hello, I am trying to use UI Automation to drive an MS Windows app (with pywinauto). I need to scrape the app's window contents and use some form of OCR to get at the texts (pywinauto can't get at them). As an alternative to integrating an OCR engine, and since I know the fonts and sizes used

Re: Rendering text question (context is MSWin UI Automation)

2007-01-23 Thread Chris Mellon
On 1/23/07, Boris Borcic [EMAIL PROTECTED] wrote: Hello, I am trying to use UI Automation to drive an MS Windows app (with pywinauto). I need to scrape the app's window contents and use some form of OCR to get at the texts (pywinauto can't get at them). As an alternative to integrating an

Re: Rendering text question (context is MSWin UI Automation)

2007-01-23 Thread imageguy
I am trying to use UI Automation to drive an MS Windows app (with pywinauto). I need to scrape the app's window contents and use some form of OCR to get at the texts (pywinauto can't get at them). As an alternative to integrating an OCR engine, and since I know the fonts and sizes used to

Re: Rendering text question (context is MSWin UI Automation)

2007-01-23 Thread Chris Mellon
On 23 Jan 2007 12:06:35 -0800, imageguy [EMAIL PROTECTED] wrote: I am trying to use UI Automation to drive an MS Windows app (with pywinauto). I need to scrape the app's window contents and use some form of OCR to get at the texts (pywinauto can't get at them). As an alternative