Table of Contents

Interface ISmartDomColumnContext

Namespace
ATAS.Indicators.SmartDom
Assembly
ATAS.Indicators.dll

Read-only view of the SmartDOM a SmartDomColumn is shown in: the instrument, the order book, the visible price range and the drawing resources. Available through Context from OnInitialize() on. The members may be read from any column callback.

Not in ATAS 8.0.15 yet: available from the next version.

public interface ISmartDomColumnContext
Extension Methods

Properties

BackgroundColor

Background color of the SmartDOM.

Color BackgroundColor { get; }

Property Value

Color

BestAsk

Best ask (price and volume), or null while unknown.

MarketDataArg? BestAsk { get; }

Property Value

MarketDataArg

BestBid

Best bid (price and volume), or null while unknown.

MarketDataArg? BestBid { get; }

Property Value

MarketDataArg

BoldFont

Bold variant of Font.

RenderFont BoldFont { get; }

Property Value

RenderFont

CumulativeAsks

Total volume of the ask levels shown in the SmartDOM.

decimal CumulativeAsks { get; }

Property Value

decimal

CumulativeBids

Total volume of the bid levels shown in the SmartDOM.

decimal CumulativeBids { get; }

Property Value

decimal

Font

Font of the cell texts selected by the user for the SmartDOM.

RenderFont Font { get; }

Property Value

RenderFont

HeaderBackgroundColor

Background color of the column headers.

Color HeaderBackgroundColor { get; }

Property Value

Color

HeaderFont

Font of the column headers.

RenderFont HeaderFont { get; }

Property Value

RenderFont

HeaderTextColor

Text color of the column headers.

Color HeaderTextColor { get; }

Property Value

Color

HighOfDay

High of the current day.

decimal HighOfDay { get; }

Property Value

decimal

Instrument

The instrument the SmartDOM displays — the one whose order book, trades and prices the column receives — or null while none is selected. For cross-trading and synthetic instruments this is the displayed (data) instrument, not the one orders are sent to. TimeZone / TimeZoneOffset are the time zone set for the instrument in the platform, as chart indicators of the instrument get them (0 for an instrument the platform does not know, e.g. a synthetic one).

IInstrumentInfo? Instrument { get; }

Property Value

IInstrumentInfo

LastTrade

The last trade, or null while there were no trades.

MarketDataArg? LastTrade { get; }

Property Value

MarketDataArg

LowOfDay

Low of the current day.

decimal LowOfDay { get; }

Property Value

decimal

MaxAskVolume

Largest volume of an ask level shown in the SmartDOM.

decimal MaxAskVolume { get; }

Property Value

decimal

MaxBidVolume

Largest volume of a bid level shown in the SmartDOM.

decimal MaxBidVolume { get; }

Property Value

decimal

RowHeight

Row height in pixels.

int RowHeight { get; }

Property Value

int

RowPriceStep

Price distance between two neighbouring rows (TickSize × Scale).

decimal RowPriceStep { get; }

Property Value

decimal

Scale

Number of ticks combined into one price row.

int Scale { get; }

Property Value

int

TextFormat

Text alignment of the cell texts selected by the user for the SmartDOM.

RenderStringFormat TextFormat { get; }

Property Value

RenderStringFormat

TickSize

Minimum price step of the displayed instrument.

decimal TickSize { get; }

Property Value

decimal

VisibleHigh

Price of the topmost row of the last drawn frame.

decimal VisibleHigh { get; }

Property Value

decimal

VisibleLow

Price of the bottom row of the last drawn frame.

decimal VisibleLow { get; }

Property Value

decimal

Methods

FormatPrice(decimal)

Formats a price the way the SmartDOM shows prices of the instrument.

string FormatPrice(decimal price)

Parameters

price decimal

Returns

string

FormatVolume(decimal)

Formats a volume the way the SmartDOM shows volumes (user's volume format, K/M shortening).

string FormatVolume(decimal volume)

Parameters

volume decimal

Returns

string

GetAskVolume(decimal)

Volume of the ask level shown in the row of price; 0 if there is none.

decimal GetAskVolume(decimal price)

Parameters

price decimal

Returns

decimal

GetBidVolume(decimal)

Volume of the bid level shown in the row of price; 0 if there is none.

decimal GetBidVolume(decimal price)

Parameters

price decimal

Returns

decimal

GetDepth(bool)

Snapshot of the bid (isAsk = false) or ask levels of the order book.

IReadOnlyList<MarketDataArg> GetDepth(bool isAsk)

Parameters

isAsk bool

Returns

IReadOnlyList<MarketDataArg>

GetPrice(int)

Price of the row at the Y coordinate y.

decimal GetPrice(int y)

Parameters

y int

Returns

decimal

GetY(decimal)

Top Y coordinate of the row of price in the last drawn frame, or null if the row is not visible.

int? GetY(decimal price)

Parameters

price decimal

Returns

int?

Redraw()

Asks the SmartDOM to draw a new frame.

void Redraw()