Style editor

From Resco's Wiki
Revision as of 10:49, 22 August 2019 by Jzambor (talk | contribs) (Created page with "Several Resco applications include a functionality that allows you to update existing styles or create completely new styles. * Woodford: styles for form and view...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

Several Resco applications include a functionality that allows you to update existing styles or create completely new styles.

Views

When editing views (lists) in Woodford, click Edit Styles on the toolbar to configure styles for image cells and text cells used in views. On project scope, the styles are shared; i.e., all entity views in a particular project share the same list of styles. It does not matter from which view you open the style editor. Click Dependencies to see all components where a style is used.

These are the properties of an image cell (used when the Kind = Image):

  • Folder – Name of the Folder under the platform folder of the Image.zip where the icons for the field values that you want to represent as pictures are stored.
  • BackColor - Color of the field’s background (color of the cell).
  • ForeColor – If the icon that you want to use, is colorized, you can change the color of it here.
  • FormatString – If you use a non-string field as a source for the image (e.g. a lookup field), the string should look like folder_name{0}.png. {0} represents the target name (name of the lookup record, according to which the image is used.
  • HorizontalAlignment – NEAR aligns the image to the left side of the cell, FAR aligns image to the right side of the cell and CENTER aligns the image to middle of the cell.
  • ImageQuery – For list note images, you can define the query for image location.
    • Select the entity and field that contains your image (often, Note or Cloud Document entity).
    • Add conditions to locate the correct image (for example Regarding = {id}).
    • Optionally, add a placeholder image (in case the query does not return anything): enter the path and name of a project image (for example mydirectory.mypic.png).
  • Name – Name of the style.
  • VerticalAlignment – NEAR aligns the image to the upper side of the cell, FAR aligns the image to the bottom of the cell, CENTER aligns the image to the middle of the cell.

These are the properties of a text cell (used when the Kind = Text):

  • AutoHeight – Adjusts the row’s height to fit the field in case the field element in designer is smaller than the font.
  • BackColor – Color of the field’s background (color of the cell).
  • EllipsisPosition
  • FontName, FontSize, FontWeight - Specify the font.
  • ForeColor – Color of the foreground element – in this case it's the text (#AARRGGBB – AA = alpha/transparency, RR = red channel, GG = green channel, BB = blue channel).
  • FormatString – You can format the way the field data is represented, e.g. you can enter a format string in the way “Personal: {0}” where Personal: is a static text and the field data is entered where the element {0} is.
  • HorizontalAlignment – NEAR aligns the text to the left side of the cell, FAR aligns text to the right side of the cell and CENTER aligns the text to middle of the cell.
  • Name – Name of the style.
  • VerticalAlignment – NEAR aligns the text to the upper side of the cell, FAR aligns the text to the bottom of the cell, CENTER aligns the text to the middle of the cell.