f



Font, size and colors of text...

I am wondering if I can change font, size and colors of text, with awk?

Tks

Steph


---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.522 / Virus Database: 320 - Release Date: 29/09/2003


0
Stephane
10/5/2003 7:09:02 AM
comp.lang.awk 3450 articles. 0 followers. Post Follow

2 Replies
1967 Views

Similar Articles

[PageSpeed] 46

Hello,

On Sun, 5 Oct 2003 09:09:02 +0200, Stephane Collas wrote:
> I am wondering if I can change font, size and colors of text, with awk?

unfortunately, such a question cannot be answered.

Sorry,
	Stepan Kasal
0
kasal
10/5/2003 9:47:26 AM
In article <blog21$la4$1@news-reader4.wanadoo.fr>,
Stephane Collas <stephane.collas@wanadoo.fr> wrote:
% I am wondering if I can change font, size and colors of text, with awk?

I wrote a program that takes some text and generates an RTF file with the
text colour changing from one colour to another. This was in response
to an e-mail thread in which several people had taken to responding in
different colours, and saying `my response in blue' `my response in
red' and on and on, until some management type said `could we stop
with all the colours?' So I responded in a gradiant from light
steel blue to chartreuse or something like that. I don't know why
people don't like outlook...

 BEGIN {
    if (ARGC != 2) {
      print "usage: gradrtf msgfile"
      exit 1
    }

    split(ARGV[1], o, /\./)

    outf = o[1] ".rtf"
    len = 0
    lines = 0
 }

 END {
    from = ENVIRON["FROM"]
    to = ENVIRON["TO"]

    if (!from) from = "255.0.0"
    if (!to) to = "0.0.255"

    split(from, f, /\./)
    split(to, t, /\./)

    # initial r,g,b and deltas
    r = f[1]; g = f[2]; b = f[3]
    rd = (t[1] - f[1])/fl
    gd = (t[2] - f[2])/fl
    bd = (t[3] - f[3])/fl

    print "{\\rtf1\\ansi\\ansicpg1252 {\\colortbl;" > outf

    cc = 1

    for (i = 1; i <= fl; i++) {
      printf "\\red%d\\green%d\\blue%d;\n", r, g, b >> outf
      r += rd
      g += gd
      b += bd
    }
    print "}" >> outf

    c = 1
    for (i = 1; i <= nl; i++) {
      ll = length(l[i])
      for (j = 1; j <= ll; j++) {
	 printf "\\cf%d %s", cc++, substr(l[i], j, 1) >> outf
      }
      printf "\n " >> outf
    }

     print "}}" >> outf
 }
 {
    fl += length
    l[++nl] = $0
 }
-- 

Patrick TJ McPhee
East York  Canada
ptjm@interlog.com
0
ptjm
10/5/2003 7:53:08 PM
Reply:

Similar Artilces:

How to make sure that font style/size in graphics matches with text font/size?
Hi, I'm writing my phd thesis with pdfLaTeX (KOMA script package with "standard" serif fonts, 11 pt) and now have to create technical drawings, schemes and diagrams. (My thesis is about engineering, so there will have to be some technical drawings and sketches, flow charts and schemes, fotos and many many graphs... I'm writing on a PowerBook with OS X, but am also working on a PC with Windows XP.) I'm not sure what software to use to create (vector) graphics and how to ensure that font size and style look good with the text of the document... Should the text in the graphs also be a serif font or should it be sans serif as a contrast? Is there any tutorial how to layout graphics to look great with a LaTeX document)? Is there an easy way (GUI appreciated) to typeset some LaTeX text over an included photo? Martin p.s. I've already been surfing and procrastinating a lot reading reviews of different apps (xFig, WinFig, Corel Draw, OmniGraffle, Inkscape, ipe, j***Edit, ...) and I'm not really sure what would be the best tool... p.p.s. WARMreader (http://www-texdev.ics.mq.edu.au/WARM/) looks very interesting - might this be the tool of choice to label graphics?... Lvood wrote: > Is there an easy way (GUI appreciated) to typeset some LaTeX text over > an included photo? http://tug.org/PSTricks/main.cgi?file=Examples/overlay Herbert -- http://PSTricks.tug.org http://www.dante.de/CTAN/info/math/voss/ Lvood: > I'm not sure wha...

Changing font color/size and background color with Tile
Hi, I'm beginning to use Tile and I would like to be able to change the font color/size and background color of the checkbutton widget on an individual basis. I understand that I can use style to change it for all of the checkbuttons, but I need to do it one-by-one. It seems like I need the -style option on checkbutton, but I'm not sure what to do. ttk::checkbutton -text "mytext" -variable myvar -style ??? Also how can I return what the name and size of the current font is in Tile for a particular widget? Thanks, Bob Lipman Robert Lipman wrote: >I'm beginning to use Tile and I would like to be able to change the >font color/size and background color of the checkbutton widget on an >individual basis. I understand that I can use style to change it for >all of the checkbuttons, but I need to do it one-by-one. If you need to do this sort of thing, then you probably don't want to use the Tile widgets. Stick with core Tk checkbuttons; the Tile checkbutton isn't designed to accommodate this usage pattern. >Also how can I return what the name and size of the current font is in >Tile for a particular widget? Unless you've explicitly specified something different, it's TkDefaultFont. (Exceptions: ttk::treeview widgets use *two* fonts -- TkDefaultFont and TkHeadingFont -- and ttk::entry widgets use TkTextFont.) Use [font configure TkDefaultFont] to find out the size, weight, and family of the default UI font on t...

Front end text formatting
Hi, I'm totally new to formatting in Mathematica. Please could someone help me make it so my default.nb does fractions that don't shrink in font size? Also, my table font is set to courier and the equations don't do italics as usual. How do I solve this? Many thanks well look hard for options - there are many that may help. here's a clue if you can't find any... on my box Mathematica doubles the Box height when I enter a faction and the fraction is the same size. try changing style sheets? Mine does that for Style Input but not Style Text. For style text the thing does get a double box size but still appears smaller StyleBox[FractionBox[x, y], FontSize -> 18] // DisplayForm shows it larger. there are a few ways you can wrap stylebox around every FractionBox whenever FractionBox is input or whenever it's output. see InputAutoReplacements for one way. Another way is to make FractionBox function yourself (call the orig. one but wrap it). Again there may be a Global Option for BoxData or RowBox I can't find that, using Style Text, chooses a bigger font. HOWEVER. If I change from Text style to Input it is changed: my 1/2 is fully double sized again automatically. ** I'd say pop open the Style Sheet and see where the difference is there ** sorry if that didn't help ...

Changing font size of text
Hi, I'm working with a rather large Simulink model and most of the blocks are put into subsystems. For a good overview I use masks to give each subsystem a name (I prefer this over the name under the block). If I use "fit the system to view" the text on the blocks becomes very small. Is there a way to change the font size of text with the drawing commands? ...

Font and size in controls and text
Is there anywhere where I can see a general rule for what fonts and sizes I should use for buttons, areas of text and so on in my app so that it fits in my other system applications? Apologies for all of the school boy style questions this afternoon, thanks for your help! Graeme In article <BE4E381B.2160%graeme@memoblock.fsnet.co.uk>, Graeme Warren <graeme@memoblock.fsnet.co.uk> wrote: > Is there anywhere where I can see a general rule for what fonts and sizes I > should use for buttons, areas of text and so on in my app so that it fits in > my other syste...

change matlab workspace font size and editor font size
dear all I wish to change the workspace font size and the editor font size. How do I do it? Thanks in advance, Thanks I have the suggestion in another question posted earlier. "langtran" <lang.tran@iom-world.org> wrote in message news:7795881.1207239680638.JavaMail.jakarta@nitrogen.mathforum.org... > dear all > I wish to change the workspace font size and the editor font size. How do > I do it? > Thanks in advance, Open the Preference window using the Preferences menu item on the File menu. There is a Fonts item in the Preferences that will let ...

size font on a text box
How can i change the size of font on a text box acording the number of character (>25 characters the font size 12 ) Something like this... Use the textbox's Exit event. Private Sub txtBox_Exit(Cancel As Integer) If Len(Me!txtBox) > 25 Then Me!txtBox.FontSize = 12 Else Me!txtBox.FontSize = 10 ' your default here End If End Sub "Themis Parintas ste kardias" <steka2@otenet.gr> wrote in message news:cilpru$k2v$1@usenet.otenet.gr... > How can i change the size of font on a text box acording the number of > character (>25 characters the font size 12 ) > > ...

Figures captions font size bigger than font size used in document
Hi, I would kindly appreciate some help if someobody could show me (if it is possible - ???) how to give a figure a caption text of the same size that is used on the text of the hole document currently set to footnotesize. While placing caption to figures the caption text is of the size "normalsize" and it is desired to have a caption with font size "footnotesize" Many work arounds were tried with the following commands, \floatingfigure \includegraphics \epsfig \minipage the web was searched and some books consulted with out success Best Regards On Tue, 24 Jan 2006 05:30:49 +0100, Lathe_Biosas <lathe_biosas@hotmail.com> wrote: > Hi, > > I would kindly appreciate some help if someobody could show me (if it > is possible - ???) > how to give a figure a caption text of the same size that is used on > the text of the hole document currently set to footnotesize. > > While placing caption to figures the caption text is of the size > "normalsize" and it is desired to have a caption with font size > "footnotesize" > > Many work arounds were tried with the following commands, > \floatingfigure > \includegraphics > \epsfig > \minipage > > the web was searched and some books consulted with out success I think you will find the caption package a great relief then. Be sure to grab the latest version from CTAN, see <http://www.ctan.org/info?id=caption>. -- Morten Perfe...

Font Size on Generic Text Only Driver
A generic text only printer is connected to an EPSON TM-U230 Receipt printer. The default font size is too small for cooks that have a bad eye sight. Is there a way to increase the font size either in the font selection panel or sending some kind of escape command in the printer commands panel? The application does not use the EPSON printer driver and we would rather have the generic device driver set the default font size. Your help would be appreciated in this matter. Andre ...

Text Selection and Font Color Bug?
Hello All, I am using the Text.SelStart, Text.SelEnd, Text.FontColor properties to color incoming rs232 strings as they are displayed in a text box. (I am snooping 2 ports and I need each port to have its own displayed color.) The problem is that when you add new text to the display it reverts all the displayed text to the starting color of the first text font. Is this a bug or some strange feature that I do not understand? Thanks The problem is that you rewrite the whole text on the indicator and LabVIEW has no clue that you just append new text and want to keep current colors. To fix...

how to set font size and color of a msgbox?
Dear all, Yesterday somebody asked this question and the solution was: -------------------------------------- hMsg=msgbox('ok', 'ok', 'modal'); set(hMsg, 'color', 'white'); -------------------------------------- but that's actually not a modal msgbox, because the codes after "msgbox" continues to run, so the color can be changed or the text size can be changed. But what if it is a modal dialog window? --------------------------------------- hMsg=uiwait(msgbox('ok', 'ok', 'modal')); set(hMsg, 'color', '...

Font size of text when printing images
Hello i have the problem that when printing images from 2 different series out of one study to a paperprinter, the demographic datas do not have the same size for the images of the different studies. Question: Where in the dicomheader are these values to find (size and fonts of the demograhhics). Any other ideas of that behavior Thanks in advance for your help Martin Hi Moser, How did you print the demographic details? Where did you say that you want demographic details printed? moser martin wrote: > Hello > i have the problem that when printing images from 2 different series out of > one study to a paperprinter, the demographic datas do not have the same size > for the images of the different studies. > > Question: > Where in the dicomheader are these values to find (size and fonts of the > demograhhics). > > Any other ideas of that behavior > > Thanks in advance for your help > > Martin Hi Ramesh i did send the studies from a pacs displaystation to a printserver (hipax) where a paperprinter is connected to. There is no option to enable/disable demographic layouts for printing, it is just a dicom-print from a pacs displaystation. ramesh.s.raghavan@gmail.com schrieb: > Hi Moser, > > How did you print the demographic details? Where did you say that you > want demographic details printed? > > moser martin wrote: > > Hello > > i hav...

Minimum font size in styled text
Eudora 4.3. I have a nice sharp monitor, set to 1200x1600 resolution. When receiving messages with styled text, often the font size is "tiny" (I expect that it would be OK if I used a lower resolution, but I'd rather not do that). Is there a Eudora setting that forces a minimum size without otherwise altering the font? I went through the list from TidBITS, but nothing looked applicable. thanks, Isaac Isaac Wingfield <isw@witzend.com> wrote: > Is there a Eudora setting that forces a minimum size without otherwise > altering the font? I went throu...

font: size, color wish list
Just putting this out - I wish if I highlighted text, I could be shown what size and color it is (by way of highlighting the item in the drop down list). Most text size/color is not reproducible (so far) for me.... sf wrote: >Just putting this out - > >I wish if I highlighted text, I could be shown what size and color it >is (by way of highlighting the item in the drop down list). Most text >size/color is not reproducible (so far) for me.... > > Assuming you are speaking about mail you receive, try hitting reply, then hilite and look at the toolbar where you set the font. It will change to what is hilited. (You need to be composing in Styled Text) [Not much help for color, though.] Rick Rick ...

Changing the font color of the stdout text.
I need to change the color of the stdout text. Do we have any simple way of doing it using any options in the stdout command looking something like this "puts -changecolor color text" I need to use it for this code snippet, which i may use in a foreach loop: puts -nonewline "=" This has already been discussed long ago ( way back in 2007 ) using tkcon in the post "http://groups.google.com/group/comp.lang.tcl/ browse_thread/thread/9bfea95a804d7dbd/5e48efb046a3864a?lnk=gst&q=change +font+color#5e48efb046a3864a". But that doesnt seem to work for me. Also i believe lot has changed after 2007 for tcl. so any new solution to make it work. (without using tk widgets). Also i use a post discussing the same using regsub. It reports: invalid command tkcon. Please help regards, iand On Jun 18, 7:27=A0am, iand <ianda...@gmail.com> wrote: > I need to change the color of the stdout text. Do we have any simple > way of doing it using any options in the stdout command looking > something like this "puts -changecolor color text" > I need to use it for this code snippet, which i may use in a foreach > loop: > puts -nonewline "=3D" If your on a Unix with a tty, try the term package from tcllib. It does things like that. For Windows there is an unfinished extension for ansi colors attached to a withdrawn TIP. Michael On Jun 17, 10:27 pm, iand <ianda...@gmail.com> wrote: > I need to change the color of the s...

Tk::Pod::Text font sizes
Hi, I figured I'd document my project in POD, and let the users view it via Tk::Pod::Text. It seems to work, but I've got complaints that the font for the normal text is too small, and I think I agree with that assessment. Looking at Text.pm, it looks like a couple calls to the zoom_in method might do the trick, but they don't seem to work properly, at least in my test code. Zoom out goes out so far that nothing is legible, zoom in doesn't seem to do much, and zoom_normal doesn't seem to do anything, even after major zoom-outs. Any clues as to get control...

font-size starting size
Hello, I just joined this group and saw the discussion "What do you think of resizing 1em to 10px?" I am somewhat confused by what y'all think should be used as a reference size. I was surprised that someone actually suggested ems as a reference. Ems are relative to a selected point size, the width in points of a capital M. If no point size is given, what size does an em become? The browser obviously must decide. Also setting the body text to 62.5% is, well, stupid. % of what? I should *assume* 16 pixels? Bad thinking. And not my experience with browsers. Using pixels does not scale very well at all. Text look quite large on a 17" 800x600 monitor, and quite small on a 20" 1600x1200 or 17" 1400x1050. Our site recently changed from using hard-coded pixel settings to assigning a default body text size in points and using % to set the other sizes up or down. It has a more consistent look that way on displays of different physical dimensions and resolutions. I used "font-size=11pt" to define the reference size (which on my display here is about 16 pixels). It is, of course, not very exact; it depends on the browser and the display system to decide on what represents 1 point (1/72 inch). So after all that.... What is considered good practice for the base font size? -- jmm dash list at sohnen-moe dot com (Remove .TRSPAMTR for email) James Moe <jmm-list.TRSPAMTR@sohnen-moe.co...

Emerald fonts
Hi there, I've installed the Emerald fonts [1] from CTAN, and have got them working on my system. An example such as the LaTeX Font catalogue's text example [2] works perfectly, but I can't work out for the life of me how to resize the font. I'm using this in the context of: \documentclass{article} \usepackage{emerald} \fontfamily{cmss}\fontsize{12pt}{13pt}\selectfont Here's the body of my text {\ECFAugie Some notes in the magin} Body text continues... \end{document} I wish to use cmss as my default font and Augie enclosed in a group only for short notes. Yet {\ECFAugie \fontsize(10pt) doesn't work as I'd hope} Thanks in advance for any pointers, Stroller. [1] http://ctan.org/tex-archive/fonts/emerald/ [2] http://www.tug.dk/FontCatalogue/augie/augie.tex Stroller <stroller@bigfoot.com> schrieb: > Hi there, > > I've installed the Emerald fonts [1] from CTAN, and have got them > working on my system. An example such as the LaTeX Font catalogue's > text example [2] works perfectly, but I can't work out for the life of > me how to resize the font. > > I'm using this in the context of: > > \documentclass{article} > \usepackage{emerald} > \fontfamily{cmss}\fontsize{12pt}{13pt}\selectfont > Here's the body of my text > {\ECFAugie Some notes in the magin} > Body text continues... > \end{document} > > I wish to use cmss as my default fo...

Font size and plot size.
Using version 7.1, I have a plot that I make and it looks fine. I put a title on the plot it looks fine. The boss wants the font of the title and x and y labels bigger, so I set(0,'DefaultTextFontSize',24); set(0,'DefaultAxisFontSize',24); as the first 2 lines of my m file. Now the plot looks like hell because the title is clipped. Why isn't matlab 'smart enough' to figure out that it needs to make the plot smaller? What do I need to do to not have the title clipped? (new boss and/or smaller font size are not viable options :-) Bruce -- +-------------...

richtext ctrl, changing font, size and color
hi there, i'm in need of a control to set different fonts, colors and sizes and so i thought i'd use richtext ctrl. now i'm in need to set those attributes for a group of chars that are selected. in the documentation i don't find any functions that could do this. are there any hints for me? i also would need functions to get the color, size and font for a specific character. kind regards --------------------------------------------------------------------- To unsubscribe, e-mail: wx-users-unsubscribe@lists.wxwidgets.org For additional commands, e-mail: wx-user...

Setting font size of text box in VBA
I want to be able to set the font size and font type for text in a text box on a report using VBA. I wan't to be able to control it from a setting in a table. The problem is that I don't know the syntax for setting either font type or font size for a text box on a report. Does anyone know? Help. Please! dixie ctlTextBox.Height = 1440 'size in twips: 1440 = 1 inch ctlTextBox.Width = 2880 'size in twips: 1440 = 1 inch 'so you can see the area covered by the textbox ctlTextBox.BackColor = RGB(255, 255, 0) ctlTextBox.FontSize = 20 ctlTextBox.FontName = "Comic Sans MS" changing the font size, name, bolding, means you may also need to change the size of the textbox correspondingly. 1 inch is 1440 twips John Bickmore www.BicycleCam.com www.Feed-Zone.com "dixie" <dixiec@dogmail.com> wrote in message news:C0%Jb.968$FD6.34284@nnrp1.ozemail.com.au... > I want to be able to set the font size and font type for text in a text box > on a report using VBA. I wan't to be able to control it from a setting in a > table. The problem is that I don't know the syntax for setting either font > type or font size for a text box on a report. Does anyone know? Help. > Please! > > dixie > > Dixie, In the Report's Detail Format event: If [SomeField] = "Something" Then [SomeField].FontName = "Ariel" [SomeControl].FontSize = "12" Else [SomeField].FontName = "...

how to set the font size for the message text in the tk_messageBox
Hi, I would to know if it is a way to do this? -- Vaclav Snajdr Hi Vaclav, sorry to say, but there is no way to change the font size of the message part of tk_messageBox. The message dialog that popup, when using tk_messageBox, is a native dialog. On MS Windows this means, that a native WIN32 function is used to create this message dialog. And this WIN32 function does not allow to change the font style or size, but only the alignment! But the change of the alignment is not available in the Tk command tk_messageBox! Best regards, Martin Lemburg UGS - a Siemens Company - Transforming the Process of Innovation On Feb 23, 1:01 pm, Vaclav Snajdr <snajdr.vac...@t-online.de> wrote: > Hi, > I would to know if it is a way to do this? > -- > Vaclav Snajdr Vaclav Snajdr <snajdr.vaclav@t-online.de> schrieb: [ subject ] Try this: option add *Font {helvetica 20 normal} tk_messageBox -message {This should not be the default font.} \ -title {Font Test} -icon info -type ok -parent . Note that this might set the default font for every widget you are creating from here on. If that's unwanted you could set it afterwards to a different font, delete such added options, or tell every widget its font especially. HTH, :) Jo Joachim Moskalewski wrote: > Vaclav Snajdr <snajdr.vaclav@t-online.de> schrieb: > > [ subject ] > > Try this: > > option add *Font {helvetica 20 normal} > tk_messageBox -message {This shou...

how to set font size text within figure?
Dear Sirs, I had this peace of tex code in my text. My tex text as a whole has 10pt size. However, I would like to set just this piece below as 9pt font size. I already tried in vain \begin{small}, but it did not make any effect. Any help will be very appreciated. Thanks in advance! Regards, Leo \begin{figure}[htb] \[ \begin{array}{llll} \multicolumn{4}{l} ${\mbox{Level-$(h)$ }} \\[2mm] & & A_{h} \rightarrow B_{h-1}: & \{\mbox{\textsf{mngt}} \mid n_A \mid m\} \\ & & \ldots \\ & & A_{h} \rightarrow D_{h-1}: & \{\mbox{\textsf{mngt}} \mid n_A \mid m\} \end{array} \] \caption{Test} \label{prot} \end{figure} "Leonardo Barbosa e Oliveira" <leob@dcc.ufmg.br> wrote in message news:Pine.GSO.4.58.0406141310000.1964@wolverine... > > > Dear Sirs, > > I had this peace of tex code in my text. > My tex text as a whole has 10pt size. However, > I would like to set just this piece below as > 9pt font size. I already tried in vain \begin{small}, > but it did not make any effect. > > Any help will be very appreciated. > > Thanks in advance! > > Regards, > > Leo <snip> Here's one way to do that (with figure caption not changing size, right?). --- Georgios Tagalakis %%%%%%%%%%%%%%% \begin{figure}[htb] {\small{ \[ \begin{array}{llll} \multicolumn{4}{l} \ensuremath{\mbox{Level-$(h)$}} \\[2mm] & & A_{h} \rightarrow B_{h-1}: & \{\mbox{\textsf{mngt}} \mid n_A \mi...

print text file with font size 8
What is the best way to print a text file to a particular printer a. with font size 8. b. with font size 8 and add line numbers, file name and date to the output. c. with font size 8 and a diff of its previous version side by side. Thanks. In article <451a2a55.0307281154.134fd42f@posting.google.com>, ma7777772@hotmail.com (TingChong) writes: > What is the best way to print a text file to a particular printer > a. > with font size 8. If it's a PostScript printer, and the text is just ASCII (no UTF-8), then /usr/lib/lp/postscript/postprint -l 0 -s 8 <file | lp -d...

Web resources about - Font, size and colors of text... - comp.lang.awk

Color - Wikipedia, the free encyclopedia
This article is about the perceptual property. For a list of colors, see Lists of colors . For other uses, see Color (disambiguation) . Color ...

Color - Broadcast Live
Host your friends. A live broadcast from your phone.

Color Grading Tutorials and Presets - Color Grading Central
Your online resource for color correction and color grading tutorials. Learn the art and skill of a Colorist. Sign up today for your FREE tutorials! ...

Color Hunter
Color palettes made from images

The Color of Crime
Perhaps the most important publication of New Century Foundation is , New Century Foundation's report on differences in crime rates by race, ...

The Color of Energy: A Mike Elsass Art Gallery
The Color of Energy: A Mike Elsass Art Gallery

Educational Resources for teaching American Sign Language - Welcome to Color of Language
Welcome to Color of Language Developing Sign Language educational materials to facilitate communication and early intervention. Join Our Email ...

Color Radio and Doo Wop
Color Radio with Brian Lee broadcasting on KVMR-FM in Nevada City, Internet radio on rockit radio.net, with the best of R+B,DOO WOP and Rock ...

Color Scheme Designer 3
A designer tool for creating color combinations that work together well.

ColorSchemer - Instant Color Schemes
Build dazzling color schemes with software from ColorSchemer

Resources last updated: 3/25/2016 8:40:58 AM