text

Modifying a window's textbox control's text

Case in point : I've got a handle to a window (for instance, using the getForegroundWindow() API function). This window's got a textbox (possibly a richtext control). Would it be possible to modify the textbox's text through an Windows API call ? More specifically, I'd like to replace its text with some of my own. ...

How to extract fields from a text line that has no constant deliminator?

What is the best way to extract each field from each line where there is no clear separator (deliminator) between each field? Here is a sample of the lines I need to extract its fields: 3/3/2010 11:00:46 AM BASEMENT-IN 3/3/2010 11:04:04 AM 2, YaserAlNaqeb BASEMENT-OUT 3/3/2010 11:04:06 AM ...

jQuery, find if element has any text

I am dealing with some generated spans and I would like to find which one of them does not contain any text. The markup is: <span id="layer6"> <span class="drag col"> Some text</span> <span class="drag col"> More text</span> <span class="drag col"> </span> <span class="drag col"> I also have text</span> </span> I ...

jQuery split only words that do not have specific class

I have the following markup: <div id ="selectable1"> <span id="layer6"> here are some words that needs to be splited <span class="good">this should not be splitted<span> this should be splitted <span class="good">and this should not be spited<span> </span> </div> I am trying to write a function that will split only the words that do n...

Extract Text based on Character - Flex

I'm using an auto complete component and a labelFunction so that user have the ability to search by their name or id. Once the search is completed I'd like to extract the data to a query. The only problem is that I only need the name or id for the query not both, so I'd like to pull from just the id variable... Currently if the user ty...

Filter a csv file by a word or text using php

I have another csv file where I am trying to do a simple word filter. For example, my text.csv file looks something like this: name, age, hobbies Tom, 8, "football, soccer, baseball, wii, star wars, books" Bill, 9, "football, baseball, ice hockey, basketball" Sue, 8, "baseball, soccer, volleyball, bicycles, skating" Mike, 8, "basketbal...

Can't Get A Simple Ajax Response

I've implemented more complex AJAX before with javascript and PHP, but for some reason this refuses to work. This is copied almost directly from the W3 example. var xmlhttp; function changeLoc(str) { xmlhttp=GetXmlHttpObject(); if (xmlhttp==null) { alert ("Browser does not support HTTP Request"); return; } var url="acti...

Detect the origin of dynamic text in JavaScript

Hi, Is there a way to detect from where the text come (if it's not pure HTML) for example document.write ('ok') will write ok somewhere in the page. But it doesn't show up in HTML, it's dynamic. My problem is that I want to know where 'ok' comes from, when I have a long/complicated source of code. Any idea? ...

Getting selected text win CKEditor Plugin

I have made a plugin for CKEditor, but it relies on the currently selected text. In FF and Chrome I can use: var selectedText = editor.getSelection().getNative(); but this doesnt work in IE and I only get [object Object] Any suggestions? ...

Is it possible to get the width of a character when using OpenGL bitmap fonts?

I am trying to align my bitmap font text in my OpenGL application but I can't find anything on getting the width of each character. This is my renderText function: def renderText( self, text, fontFace, position ): ..... (omitted code to make post shorter) glRasterPos2i( position[0], self.windowSize[1] - position[1] ) glPushA...

How can i get a paragraph from a text file in c#

I have something like this: "Content-Transfer-Encoding: base64 UEsDBBQABgAIAAAAIQDfz5sukgEAAJQGAAATANwBW0NvbnRlbnRfVHlwZXNdLnhtbCCi2AEooAAC AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA" That ends with a line like this: "DwAPAPADAAA7KQAAAAA=" It is a file with MIME format, i thought about putting "ba...

UIImage with text problem

Hi. I have a UIImage with some text I´ve done it creating a RGB Context, after that I use drawinrect method to write the text on that context and finally I create a CGImage with CGBitmapContextCreateImage function. Then I have a black background with white text over. What I want now is to change the white pixels (text) for other value (...

Crystal Reports Cutting Off Text in PDF

I saw the other post with a similar title but there was no answer to my problem and I was unable to post a comment so I'm asking a new question. I have a Crystal Report that contains a field within a text object (to control line spacing) and has "can grow" selected. When I export the Crystal Report to a PDF there are instances when th...

How to alter colors in mac/cocoa text views

Is there a way to alter the standard background and text colors in cocoa text views throughout the mac os? Since the same text system is used by textedit, mail and other programs, I imagine there is an underlying preference that could be altered. Any ideas how to access it? Just to be clear, I don't mean simply to alter the document col...

vertical text won't be bold in win32 GDI c++

I'm trying to draw vertical text in win32 GDI api. I call CreateFont() with 2700 for the angle and 900 for bold. logPxlY = ::GetDeviceCaps (c->_hdc, LOGPIXELSY); _hfont = ::CreateFont (-::MulDiv (point, logPxlY, 72), 0, angle, weight, 0, FALSE, FALSE, FALSE, 0, 0, 0, 0, FIXED_PITCH | FF_MODERN, face); where face is "Courier Ne...

NSTextField or NSTextView?

Could someone explain to me what are the main differences between NSTextField and NSTextView? I know that NSTextView has more features and is usually used for longer texts, and NSTextField is usually used for one-line plain text fields, but if I understand correctly, NSTextField can be also used with attributed strings and with multiple ...

iPhone architect choice for large text flow w/links

I am designing an app which will present large amounts of text that is interspersed with notes and references as clickable images. On a PC I'd use a control that shows HTML, but in the iPhone I am not able to intercept the touches of images and links too well using the UIWeb control. Should I use a UIScroll and build the text as lables ...

How to customize the full text search ?

Full text search is becoming a tedious job using the relational databases’ approach. Can anybody suggest an alternate option if any or way to customize the full text search ? ...

How to check if text is "empty" (spaces, tabs, newlines) in Python?

How can I test if the string is empty in Python? For example, "<space><space><space>" is empty, so is "<space><tab><space><newline><space>", so is "<newline><newline><newline><tab><newline>", etc. ...

Convert HTML to Plain Text using c++

Hi I am doing mail parsing application which required to convert the HTML file to Plain Text. regarding this i have found some scripts which does conversion. I want to do same thing in C++. So please suggest me any Cross platform and open source C++ libraries for converting HTML to Plain Text. Thanks in advance Regards Subbi ...