Log of /trunk/gui/ged/inc/TStylePreview.h
Parent Directory
Revision
12688 -
(
view)
(
download)
(
as text)
(
annotate)
-
[select for diffs]
Added
Thu Sep 8 14:22:17 2005 UTC (9 years, 4 months ago) by
brun
Original Path:
trunk/ged/inc/TStylePreview.h
File length: 2162 byte(s)
From Ilka & Denis:
The Style Manager handles a list of styles in the ROOT session. It loads by
default the five styles provided by ROOT: Default, Plain, Bold, Video, and
Pub. If this list does not contain a style with the characteristics you
want, you can create a new one and than apply it.
The Style Manager interface is composed of two parts:
- the top level interface that manages a list of styles;
- the style editor, which deals with the current style settings.
The combo box 'Available Styles' contains the list of available styles for
the current ROOT session and the currently selected one. The field on the
right shows the setting of the gStyle. You can set the global variable
gStyle to the selected style by the button in the middle.
The group frame 'Apply on' displays information for the currently selected
canvas and object in the ROOT session. This selection might be changed by
clicking on another object with the middle mouse button. You have a choice
to apply the selected style on the selected object or on all available
canvases. WARNING: You cannot undo the changes after applying the style! If
you are not sure of that action, it may be better to see a preview of what
you are going to apply.\n"
If the check button 'Preview' is selected, a preview of the selected canvas
according to the selected style will be shown. The selection of the next
check button 'Run Time Preview' will apply updates of the preview any time a
value of the selected style is changed. For drawings that take a time it is
better to disable this option.
Create a new style / delete a style:
You can access these functionalities via the menu or the tool bar. If you
create a style, a clone of the selected style will be created; you will have
the opportunity to modify it later via the editor. Moreover, during the
creation process, you will be asked for a name and a description for your
brand new style. The name can obviously not be the same as another already
existing style. When you choose 'delete', the selected style is removed from
the ROOT session. The selected style will be lost if you didn't saved it in
a C++ macro file before.
Export a style (in a C++ macro file) / Import a style (from a macro):
To store a style longer than for one session of ROOT or in order to share
some styles with others, you can save it in a C++ macro file. This can be
done via the menu and the tool bar. The selected style will be saved. The
name of the macro must be 'Style_*.C', where * can be replaced by anything
you want. A style macro can be imported at any time. The new imported style
in ROOT will become the selected one.
Apply a style (on an object) / Import a style (from an object):
There is a specific button to apply a style on an object and its use has
already been described in the overview. To import a style from a canvas,
choose the 'Style / Import from... / Canvas' menu or the corresponding Tool
bar button. A new style will be created in the ROOT session and will become
the selected one. This style is a clone of gStyle where every style's
information contained in the selected canvas (the canvas containing the
current selected pad) is written. You can consequently import a style from a
canvas and apply it later on another object.
Preview a style:
The predicted result when applying a style can be seen if the 'Preview'
check button is selected. The preview includes the original canvas.
Editor's buttons:
Open / close the editor:\n"
The button 'Edit >>' opens the style editor. Its label changes to 'Close
<<'. For all details of what can be changed and how please see the provided
Help on the right of the Style Manager menu bar.
Reset a style (to a previously saved state):
When the editor is opened, in the bottom of the main window of the style
manager, a 'Reset' button enables you to reset the values of the selected
style. So doing, you cancel all changes made since the last time you saved
that style in a macro file. If the selected style is one of the five
predefined styles of ROOT (Plain, Bold, Video, Pub or Default), it will be
reset using the specific code in the ROOT files.
Update the preview:
The button 'Update Preview' is available when a preview is shown and the run
time option is disabled. This button allows you to refresh the preview and
to see how the edited style looks like.
This form allows you to request diffs between any two revisions of this file.
For each of the two "sides" of the diff,
enter a numeric revision.