N ATIONAL E NERGY R ESEARCH S CIENTIFIC C OMPUTING C ENTER Charles Leggett Colors in the Message Service ATLAS software workshop March 3 2003 Architecture.

Slides:



Advertisements
Similar presentations
Microsoft® Word 2010 Training
Advertisements

HTML popo.
Microsoft® Word 2010 Training
Computer Applications.  Informative  Sales  Persuasive.
Power Points By Alex Fields Bullets This is the default bullet YYou can change bullets by clicking on “Format,” then “Bullets and Numbering”  T There.
Microsoft ® Word 2010 Training Create your first Word document I.
CSS The basics { }. CSS Cascading Style Sheets - language used to – describe html appearance & formatting Style Sheet - file that describes – how html.
INTRODUCTION TO HYPERTEXT MARKUP LANGUAGE 1. Outline  Introduction  Markup Languages  Editing HTML  Common Tags  Headers  Text Styling  Linking.
Session 4 Managerial Spreadsheet Modeling -- Prof. Juran1.
Important Irvine Library Procedures Randomize Randomize –Initializes the seed of the random-number formula by both the Random32 and the RandomRange procedures.
Bourne Shell Prompt CIS 218. BASH Prompt Prompt is controlled via a special shell variable PS1, PS2, PS3 and PS4. If set, the value is executed as a command.
© red ©
13 February Building a Web Page. HTML Files Two types of information Text Instructions on how to display Instructions are in the form of tags Tags are.
Screen Display Module M15.2 Sections 9.5, 13.1, 13.2.
Adv Graphical Enablement In this presentation… –Working with color schemes. –Working with newlook filters. –Tips to assist recognition of the iSeries 5250.
Honeywell Guidelines for PowerPoint
Or CMD/BATCH.  Title this comand makes the cmd prompt’s title whatever you would like it to be.
Creating Web Pages with Links, Images, and Formatted Text.
POWERPOINT GUIDELINES For use during Telematic broadcasts.
Chapter Nine Advanced Shell Scripting1 System Programming Advanced Shell Scripting.
© Copyright by Deitel & Associates, Inc. and Pearson Education Inc. All Rights Reserved. Tutorial 26 – CheckWriter Application Introducing Graphics.
– Introduction to the Shell 10/1/2015 Introduction to the Shell – Session Introduction to the Shell – Session 2 · Permissions · Users.
ECE291 Computer Engineering II Lecture 9 Josh Potts University of Illinois at Urbana- Champaign.
Copyright (c) 2004 Prentice-Hall. All rights reserved. 1 Committed to Shaping the Next Generation of IT Experts. Formatting Text and Lists Essentials for.
Tutorial 5 Formatting with CSS. Objectives Session 5.1 – Evaluate why CSS styles are used – Determine where to write styles – Create an element selector.
Microsoft Word Objective: Understand Basic Word/Word Processing Skills Lesson: Create and Save a New Document LOL: Understand/Apply Create your first Word.
N ATIONAL E NERGY R ESEARCH S CIENTIFIC C OMPUTING C ENTER 1 ACAT 2000, Fermilab Oct Control States... Control States for the Atlas Software Framework.
Guide To UNIX Using Linux Third Edition Chapter 8: Exploring the UNIX/Linux Utilities.
N ATIONAL E NERGY R ESEARCH S CIENTIFIC C OMPUTING C ENTER Charles Leggett Updates to Interval of Validity Service (IOVSvc) ATLAS Software Week Dec
Programmable Logic Training Course HDL Editor
© Copyright 2012 by Pearson Education, Inc. All Rights Reserved. Chapter 9 GUI Programming Using Tkinter 1.
N ATIONAL E NERGY R ESEARCH S CIENTIFIC C OMPUTING C ENTER Charles Leggett Interval of Validity Service IOVSvc ATLAS Software Week May Architecture.
Microsoft ® Word 2010 Training Create your first Word document I.
Word Processing Fonts and Styles. Fonts An array of pictures indexed by an ASCII character code.
N ATIONAL E NERGY R ESEARCH S CIENTIFIC C OMPUTING C ENTER Charles Leggett Callbacks May
12/20/20151 Color Fall, 2010 Modified by Linda Kenney 10/26/10.
1 Using Conditional Formatting & Data Validation Applications of Spreadsheets.
Excel 2010 Formatting Cells. Formatting text To change the font:
N ATIONAL E NERGY R ESEARCH S CIENTIFIC C OMPUTING C ENTER Charles Leggett Prototype GEANT4 Service for ATHENA framework ATLAS Software Workshop Dec 3.
Text Reader And Typer Project By: Brandon Smith. What it does ● First, a picture containing text is used as an input. ● The program scans it for distinct.
CS-401 Computer Architecture & Assembly Language Programming Lecture-16 Display Memory.
UNITS OF MEASUREMENT 2.01 Understand Digital Raster Graphics.
Experiment #1 Measurement of Resistance
CNIT 131 HTML5 - Tables.
The Internet 10/11/11 Fonts and Colors
Insert Presentation Title and Author’s names
What is HTML? Structure of HTML Document HTML TAG HEAD TAG TITLE TAG
2.01 Understand Digital Raster Graphics
Dreamweaver – Project #1
Microsoft® Word 2010 Training
Microsoft® Word 2010 Training
Microsoft® Word 2010 Training
POWERPOINT GUIDELINES
What is HTML? Structure of HTML Document HTML TAG HEAD TAG TITLE TAG
The Internet 10/13/11 The Box Model
Microsoft Word Text Basics.
PowerPoint Slide Design
Cascading Style Sheets Color and Font Properties
Two ways to discuss color 1) Addition 2) Subtraction
What is HTML? Structure of HTML Document HTML TAG HEAD TAG TITLE TAG
Signature: Microsoft Word 2003
What Color is it?.
Lesson 13 Editing and Formatting documents
POWERPOINT GUIDELINES
Stylin’ with CSS.
POWERPOINT GUIDELINES
POWERPOINT GUIDELINES
POWERPOINT GUIDELINES
Java-Assignment #4 (Due, April. 9, 2004)
Presentation transcript:

N ATIONAL E NERGY R ESEARCH S CIENTIFIC C OMPUTING C ENTER Charles Leggett Colors in the Message Service ATLAS software workshop March Architecture Session

2 Charles Leggett How Colors are Generated â Only works for xterms (or things that work like xterms, eg kterm, gterm, etc). â Uses escape (denoted as ^[ ) sequences: l ^[[91;1mRED^[[m  RED â Escape sequences can be used to set foreground and background colors, as well as font attributes, such as bold, underlined, italics, and blinking. â Support for italics and blinking not well supported by some versions of xterms. â I will never implement any blinking controls as blinking is evil.

3 Charles Leggett Defaults â By default, no colors are shown, and no escape sequences are inserted into the output stream. This prevents log files from getting cluttered up. â Once colored output is activated, the default is to print all warning messages in yellow, error messages in red, and fatal messages in blue on red. This can be overridden as desired. â The colors of all levels of messages sent to the message service can be individually set. â Specific text can also be colored. fatal messages in blue on red

4 Charles Leggett â To enable colored output, in jobOption: messageSvc.useColors = true; â To set individual colors for the message levels, in the jobOption as vectors of strings: MessageSvc.fatalColorCode = { " blue ", " red " }; MessageSvc.errorColorCode = { " white ", " red " }; MessageSvc.warningColorCode = { " yellow " }; MessageSvc.infoColorCode = { " cyan " }; MessageSvc.debugColorCode = { "" }; MessageSvc.verboseColorCode = { "" }; â First color is the foreground, second which is optional, is the background.Usage

5 Charles Leggett Usage â Alternatively, you can specify the xterm escape sequence: MessageSvc.fatalColorCode = { "[94;101;1m" }; MessageSvc.errorColorCode = { "[97;101;1m" }; MessageSvc.warningColorCode = { "[93;1m" }; MessageSvc.infoColorCode = { "[96;4m " }; MessageSvc.debugColorCode = { }; MessageSvc.verboseColorCode = { }; â You have to specify the actual escape sequence you want to use, minus the initial escape character. Color codes are appended at the end of this talk, and in the docs. This also allows you to set the font attribute.

6 Charles Leggett â To set the color of individual text, in your C++ code: l MsgStream::setColor( MSG::Color textColor ); l MsgStream::setColor( MSG::Color foreground, MSG::Color background ); l MsgStream::resetColor(); MsgStream log(msgSvc(),name()); log.setColor(MSG::GREEN); log << MSG::INFO << “This is in green. ”; log.setColor(MSG::YELLOW, MSG::BLUE); log << “This is in yellow on blue. ”; log.resetColor(); log << “This is back to normal” << endreq;  setColor() sets the bold attributeUsage

7 Charles Leggett Allowed Values â xterms only have a limited (8) range of colors allocated to them. These are: black MSG::BLACK red MSG::RED green MSG::GREEN yellow MSG::YELLOW blue MSG::BLUE purple MSG::PURPLE cyan MSG::CYAN white MSG::WHITE â These colors names are recognized by the MsgStream::setColor() command. â Any other string used as a jobOption will result in a your default color in bold.

8 Charles Leggett Example Output â What it looks like

9 Charles Leggett Release Schedule â Will be part of Gaudi v12. â in release 6.1.0

10 Charles Leggett xterm Color Codes â Format: ^[[ xx ; z m set foreground color ^[[ xx ; yy ; z m set foreground and background colors  xx : foreground colors, n=0,7 l 30+n == low intensity, l 40+n == low intensity, reverse video l 90+n == high intensity l 100+n == high intensity, reverse video  yy : background colors, n=0,7 l 40+n == low intensity l 100+n == high intensity  The last character ( z ) before the “m”, is the font modifier: 1 == bold, 2==normal, 4 == underlined

11 Charles Leggett Normal Attribute

12 Charles Leggett Bold Attribute