How to interpret input text properties?
Mostrar comentarios más antiguos
Hi,
I was wondering if there is a way to analyze an entered text string based on its properties including font size, boldness, being italic,... . As MATLAB treats texts in RTF form, it seems a bit difficult to do such a thing. However, since there are many ways to control text properties (e.g. function text), it may be possible to get/interpret an entered text by the user. Is it possible to use GUI objects for this purpose?
To be more specific, I want a user to enter a text as input containing bold and italic words, so I could understand his/her text formatting (for other purposes).
Thanks in advance for your help.
1 comentario
Stephen23
el 21 de Mayo de 2016
"As MATLAB treats texts in RTF form" please give a link to the documentation that states this.
Respuestas (1)
Walter Roberson
el 21 de Mayo de 2016
0 votos
MATLAB does not treat text as RTF; MATLAB treats text as plain text with a system-dependent default encoding that is typically ISO-8896-1 or Windows 1252 or UTF-8.
There are functions available that can input RTF; there are other functions that can input some of the document formats.
There is no way for users to enter anything other than plain text or perhaps 16 bit Unicode at the command prompt or in a uicontrol style edit. If a user were to drag and drop something from a formatted document, the formatting would be removed automatically.
You might perhaps be able to get further by creating a Java window to drag and drop into; I don't know.
Categorías
Más información sobre Whos en Centro de ayuda y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!