!###################################################################### !# !# Name: code/ui/src/Itex.sample !# !# Revision: %I%, %E% !# !###################################################################### !# !# This file contains a list of perceived "scenarios" that in some way !# affect the resources. These "scenarios" are believed to cover the !# most common needs to change the resources. If we are wrong we would !# appreciate it if we would be notified of what is missing. !# !# !# Each scenario contains the set of resources to change and an !# example of what to set them to. They are ment to be mixed freely so !# that for example the user can adopt two ore more of these scenarios !# simultaneously (although this may need some adjusting if the !# scenarios need to change the same resource). !# !# !# The resources that the user need can either be copied into the !# users .Xdefaults file or into the users Itex resource file (both !# files normally reside in the users home directory). !# !# If the changes are to be site wide, then the resource file Itex !# in the installation need to be modified instead. In most cases !# this only means to append the new resources to the end of the !# resource file. !# !###################################################################### !# PAPER SIZE !# !# The default is to use the A4 format. !# Other formats available are: Letter, Legal and Tabloid. !# For each format it is possible to choose portrait or landscape mode. !# !# It is possible to specify margins at the edges of the paper. !# The resources for this is given below. !# !# When the format is changed, the width of the table window on the !# screen need to be changed too. This value is in pixels on the screen. !# Itex.paperFormat: Letter Itex.editor.width: 628 ! or Itex.paperFormat: Legal Itex.editor.width: 628 ! or Itex.paperFormat: Tabloid Itex.editor.width: 808 ! ! If landscape mode is used, suitable settings are: ! Itex.landscapeMode: True Itex.paperFormat: A4 Itex.editor.width: 858 ! or Itex.landscapeMode: True Itex.paperFormat: Letter Itex.editor.width: 808 ! or Itex.landscapeMode: True Itex.paperFormat: Legal Itex.editor.width: 1024 ! or Itex.landscapeMode: True Itex.paperFormat: Tabloid Itex.editor.width: 1240 ! ! The default values for the margins on paper are given below. ! They may also be changed. The values are given in the default unit ! used by PostScript, 1/72 of an inch. ! Itex.print.innerMargin: 72 Itex.print.outerMargin: 36 Itex.print.topMargin: 72 Itex.print.bottomMargin: 72 !###################################################################### !# CHANGE OF FONT FAMILY !# !# This scenario is that there is a need to change the font family !# used to visualize the tables. !# !# !# If we for example want to change from the default helvetica font !# family to the times font family do: !# ! ! Change the font family to times. ! Itex*table*title.fontList: -adobe-times-bold-r-normal--12-*-*-*-*-*-*-* Itex*table*columnTitle.fontList: -adobe-times-bold-r-normal--10-*-*-*-*-*-*-* Itex*table.leadTexts.fontList: -adobe-times-bold-r-normal--10-*-*-*-*-*-*-* Itex*table.fields.fontList: -adobe-times-medium-r-normal--10-*-*-*-*-*-*-* !###################################################################### !# MAKE TABLES BIGGER ON SCREEN !# !# This scenario is that there is a need to make the table editor !# bigger than default without changing the paper format. !# !# Normally the font sizes used are: !# !# title 12 !# columnTitle 10 !# leadTexts 10 !# fields 10 !# !# Lets say we want to have the fields in size 14, (ie. scale by a factor 1.4). !# We have to scale everything else by the same factor: !# !# title 18 (12 * 1.4 ~ 17) !# columnTitle 14 (10 * 1.4 = 14) !# leadTexts 14 (10 * 1.4 = 14) !# fields 14 (10 * 1.4 = 14) !# !# The reason why the title font is 18 and not 17 (12*1.4) is that there !# arn't any predefined fonts with size 17. !# Itex.editor*table*title.fontList: -adobe-helvetica-bold-r-normal--18-*-*-*-*-*-*-* Itex.editor*table*columnTitle.fontList: -adobe-helvetica-bold-r-normal--14-*-*-*-*-*-*-* Itex.editor*table.leadTexts.fontList: -adobe-helvetica-bold-r-normal--14-*-*-*-*-*-*-* Itex.editor*table.fields.fontList: -adobe-helvetica-medium-r-normal--14-*-*-*-*-*-*-* ! ! We also need to scale the graphics by the factor 1.4 ( = 140% ). ! Itex.editor.scale: 140% ! ! To be able to see the whole width of the table it must be scaled too. ! If the width was 614 before it should be 860 ( 614 * 1.4 ) now. ! Itex.editor.width: 860 ! ! If the windows default height are to be changed too, use this. ! Itex.editor.height: 500 !###################################################################### !# CHANGE COLUMN WIDTHS !# !# This scenario is that there is a need to change the relative widths !# of the columns of a certain type of table. !# !# !# The special value "0" in a column width specification means that !# the column is to receive what is left over when the other columns !# have got their specified shares. If more than one column have this !# special value, they receive equal shares of the remaining width. !# The default value for all column specifications not otherwise set !# is "0". !# !# This means that if a whole table type is unset this will give equal !# width to all columns of the table (this is the case with most !# tables in the standard setup). !# !# For example to change the column widths in the TestCase type of !# table to give more room to Behaviour Description (column 3) at the !# expense of reducing the width of Comment (column 6). This example !# only covers the portrait rotation values, similar reasoning can be !# applied to landscape rotation values. !# !# To change the format of other type of tables, replace the name !# TestCase in the example below with the name of the table. !# The names used are the keywords used in MP format without the !# initial "$Begin_", e.g. TS_VarDcls. !# ! ! The default column width values for TestCase tables in portrait rotation are: ! !Itex.TestCase.col1.portraitWidth: 5% !Itex.TestCase.col2.portraitWidth: 7% !Itex.TestCase.col3.portraitWidth: 0 !Itex.TestCase.col4.portraitWidth: 25% !Itex.TestCase.col5.portraitWidth: 10% !Itex.TestCase.col6.portraitWidth: 15% ! ! Increase the width of column 3 and reduce the width of column 6. ! As the previous value of col3 is 0 and it is the only column with ! that value it is already setup to receive all width not assigned to ! any other column, so we do not need to change it. To reduce the ! width of column 6 we simply reduce the value assigned to col6. ! Itex.TestCase.col6.portraitWidth: 10% !###################################################################### !# ROTATE PAPER !# !# This scenario is that there is a need to print the tables rotated !# 1/4 turn (this is commonly called landscape mode). !# !# !# Observe that this also changes the appearance in the table editor !# so that it is perhaps desirable to change the table editor window !# geometry simultaneously. !# ! ! Use landscape rotation when displaying tables. This affects both ! screen and paper appearance. ! Itex.landscapeMode: True ! ! Change table editor window geometry to something larger. ! Itex.editor.width: 860 Itex.editor.height: 500 !###################################################################### !# PRINT WITH DOUBLE LINE HEADER/FOOTER !# !# This scenario is that there is a need to print with a two line !# header or footer. !# !# !# Observe that this will make the the header/footer taller so we need !# to allow for that by increasing the headerOffset resource. !# !# Note that it is possible to make print output several of these !# strings on top of each other, so make sure there are no such !# "collisions" when changing these resources. !# ! ! Use a two line right header. Make sure that the header do not ! overwrite the title of the topmost table. ! Itex.print.headerOffset: 20 Itex.print.*.rightHeader: %F\n%V !###################################################################### !# CHANGING THE HEADER/FOOTER FOR PRINT !# !# This scenario is that there is a need to print with a user defined !# header. !# !# The following resources may contain embedded formatting directives. !# The meaning of the different %-directives are: !# !# %P - Current page number in decimal !# %T - Time/date printing started, same format as the date(1) command !# %D - Date printing started, format: "Apr 18, 1993" !# %V - Version string, currently: "ITEX-DE 3.0" !# %F - For string, same as: "%U@%H" !# %U - User name !# %H - Host name !# %S - Test suite name !# %% - A single % !# ! ! This adds the word "Printed:" before the current date in the header. ! Itex.print.burst.subTitle: Printed: %T !##################################################################### !# ADDING CUT/COPY/PASTE KEYS !# !# The scenario is that a user is working on a HP700-machine, which !# does not have any of the keys "Cut", "Copy" or "Paste", which is !# common on Sun keyboards. The user do probably want these keys, !# as it should make copy-pasting of text much easier. !# !# In the following example it is assumed that the user chooses !# to bind the keys "F5" to do Cut, "F6" to do Copy and "F7" to do Paste. !# !# Note that the Motif standard key bindings of "Shift-Delete" for Cut, !# "Ctrl-Insert" for Copy and "Shift-Insert" for Paste is also available. !# ! ! Use keys F5, F6 and F7 as Cut, Copy and Paste respectively. ! Itex*defaultVirtualBindings: \ osfCancel : Escape \n\ osfLeft : Left \n\ osfUp : Up \n\ osfRight : Right \n\ osfDown : Down \n\ osfEndLine : F33 \n\ osfBeginLine : F27 \n\ osfPageUp : F29 \n\ osfPageDown : F35 \n\ osfBackSpace : BackSpace \n\ osfDelete : Delete \n\ osfInsert : Insert \n\ hpInsertLine : Insert \n\ osfAddMode :Shift F8 \n\ osfHelp : Help \n\ osfMenu :Shift F10 \n\ osfMenuBar : F10 \n\ osfCopy : F16 \n\ osfPaste : F18 \n\ osfCut : F20 \n\ osfUndo : F14 \n\ osfClear : Clear \n\ \ osfCut : F5 \n\ osfCopy : F6 \n\ osfPaste : F7 !##################################################################### !# MAKE PASTE REMOVE NAME !# !# The scenario is that a user want the Paste functionality !# in the Browser to clear the name of the objects pasted. !# ! ! Make Paste in the Browser clear the name of pasted objects. ! Itex.paste.keepPreviousName: False !##################################################################### !# USE ABBREVIATED COLUMN TITLES IN BEHAVIOUR TABLES !# !# The scenario is that a user want the behaviour tables to use !# the abbreviated form of column titles in both the table editor, !# i.e. on screen, and also in the Print tool, i.e. on paper. !# ! ! Use abbreviated column titles in behaviour tables. ! Itex.useAbbrevCols: True