Linked Questions
10 questions linked to/from Highlighting text with StringReplacePart but also using Style, Subscript
60 votes
5 answers
7k views
How to join two Style[]d strings
Does anyone know whether it is possible to combine\join two styled strings? That is, while the following code works fine: omega = "text"; omega<>omega ...
23 votes
4 answers
1k views
Defining functions in stylesheets
Is there a way to define functions in a stylesheet? So far I have managed to write my stylesheets without the need to use my own custom functions or definitions. For instance, maybe I have some color ...
19 votes
1 answer
3k views
How to strip all formatting from a string and convert it to plain text?
The documentation on String states: But if I try to perform some manipulations on this string, for example, take 2 words from the left, I get some shards of ...
19 votes
3 answers
1k views
Highlighting pattern strings in a large text
I would like to apply Style to strings that are matched, for example, with one or more specified patterns or regular expressions, a string or a list of both, ...
8 votes
3 answers
1k views
How to change the word's color in string
The picture I load is my target: This is my code in mathematica ...
3 votes
3 answers
2k views
How do I make a single character bold?
I have a string of characters, like "CDABOZPVRYXSWQEGNILUTHMKJF" and want to convert it to a string in which the character at position ...
7 votes
2 answers
557 views
Formatting text through pattern matching
I am trying to format some text based on some patterns. ...
3 votes
2 answers
992 views
Highlighting or coloring certain words / substrings appearing in a larger string
I have one longer string, longString, and a set $S$ of shorter strings {ss1,ss2,ss3,...}. I'd like to print out ...
3 votes
1 answer
375 views
How to create a multicolored string? [duplicate]
I'm interested in displaying a string composed from sub-strings of different colors. Mathematica allows one to create a list comprising sub-strings of different colors, for example ...
1 vote
2 answers
233 views
Colorize letters in the given string [duplicate]
How can I colorize letters in the given string? For instance: string = "jaonvtaqhsy" How to colorize 3 letters in the middle of ...