Trading & Order Management

Orders during a replay go through the same accounting path a real terminal uses: bid/ask prices, spread cost, order types, working orders, partial closes. The difference is that fills happen against historical bars you are advancing yourself.

Two-price model

  • The chart shows the bid series, and the ask is derived from it through the spread — a fixed pip value you chose, or the dataset's real recorded spread when you imported ticks.
  • Buys fill at ask, sells fill at bid. Stop-loss and take-profit levels are judged on the bid side, and pending-order triggers use the bid or ask series appropriately, following the MetaTrader convention. That is what makes spread a real cost in your statistics rather than an afterthought.
  • Because of this, the same setup can produce a slightly different result with a wider spread. That is intended: it models what you would have paid.

Order types

  • Market — filled at the current price of the bar you are standing on.
  • Limit — filled when price trades through the level from the unfavorable side.
  • Stop — triggered when price reaches the level from the unfavorable side.
  • Pending orders are stored with their full parameters (size, SL, TP) and are checked against each bar's high/low. When the bar starts beyond the trigger, the order fills at the trigger price and the excursion is recorded, not silently re-priced.
  • A pending order must sit on the right side of the market: a Buy Limit below the ask and a Buy Stop above it, a Sell Limit above the bid and a Sell Stop below it. An order on the wrong side is refused with the reason instead of filling at once.
  • Whatever you do — open a trade, move a stop, place a limit — is checked only against the prices that come after it, never against the part of the bar already on screen. With Beat mode on a higher timeframe that means the next base candle. The same inputs always produce the same trade.

The order ticket

  • Choose Market or Pending, then click the SELL (bid) or BUY (ask) box: the box itself sends the order and says what it sends. A pending order is a Limit or a Stop by where its price sits — below the market, SELL sends a Sell Stop and BUY a Buy Limit; above it, a Sell Limit and a Buy Stop.
  • Size in lots, or as a risk % of the balance; the ticket works out the lots from the stop.
  • Stop loss in pips or at a price. Take profit in pips, at a price, or as R, a multiple of the stop distance.
  • Multiple targets (under Advanced): any number of targets, each at its own R. The lots are split equally by default, and each target becomes its own position under one shared stop. An option moves the stop of the rest to the entry when the first target is hit.
  • The chart previews the order in its own color (orange by default), with dotted lines and outlined NEW labels on the other side from your trades. The Sell | Buy switch at the top of the ticket picks the side of the preview and of its risk / reward; sending an order does not change it. Dragging the preview changes the ticket, and dragging its stop past the entry flips the order from Sell to Buy (or back), the target following with the same R. It stays on after an order is sent; Show on chart turns it off.

Trade lines on the chart

  • Every position and pending order is a line with a label next to the price axis: buys in blue, sells in red (both colors are in the settings). A position's label shows its side, lots and open profit, for example ▲ B 0.10 | +$12.40.
  • Each stop and target shows what it is worth, for example SL | −$10.00 · −10.0 pips. Drag the line or its label to move it; Esc puts it back. A stop or a target can't be dropped past the market price.
  • While a position has no stop or no target, its label shows SL and TP handles: drag one out to set the level.
  • The ✕ on a label closes the position, cancels the order, or removes the stop or target. With Confirm before closing from the chart on, the first click asks Close? and a second click closes.
  • An order with multiple targets shows one entry line (▲ B 0.30 · 3 targets), one shared stop and a line per target. Its ✕ closes them all, and moving the stop moves it for every target. In the tables, the targets sit under one row that opens.
  • A pending order is a dashed line (BUY LIMIT 0.10); dragging it moves the order price, and its stop and target move with it.
  • Trades on the same side at the same price share one line (▼ S 1.10 ×11), and so do their stops and targets (SL ×11). The ▾ lists every trade with its own ✕, stop and target handles and drag grip; dragging the shared line moves the level for all of them, and its ✕ asks before closing them all.
  • When lines are close together, their labels sit side by side instead of on top of each other.

Protective levels

  • A required stop-loss option refuses trades without a stop.
  • Break-even stop moves a winner's stop to entry automatically once a configurable profit distance is reached.
  • SL and TP can be dragged straight on the chart, on open positions, pending orders and the order ticket's preview alike.
  • A bar that touches both your stop and your target on the same candle is resolved by bar direction for OHLC data, or by the real tick order when the dataset is a tick dataset. The result tells you which assumption was used.

Sizing

  • Volume is in lots; contract size and pip size depend on the instrument, and precious metals are converted with their own pip value rather than the FX formula.
  • Risk-based sizing sets volume from a risk percentage of equity and the stop distance. For instruments where the pip value is not fixed in the account currency, the estimate is shown and the exact figure is settled when the position closes.

Closing

  • Close, partial close (in lots or percent, with correct P&L apportionment), and close all.
  • Closing an oversized partial close is rejected instead of flipping the position.
  • Break-even stops that fire on a partial close are netted per lot, not re-armed on the remaining volume.

Prop-firm mode

When prop rules are on, the replay enforces them while it runs: daily loss limit, maximum total drawdown, profit target, minimum trading days, consistency rule, a trading-hours filter and end-of-day auto-close. The result verdict distinguishes a finished target from a breached limit, and a breach that happened inside a candle is still caught — the engine walks the bar's path rather than only its close.

MT5-style toolbox

A bar under the chart always shows the account — balance, equity, floating P&L, margin, free margin and margin level, live with every candle — for as long as a test is open. Above it sits the toolbox with four tabs; the briefcase button on the left toolbar, the chevron in the toolbox header and Esc hide only that toolbox (the tabs and tables), never the account bar, and the Details button on the bar brings the toolbox back. The right panel holds only the order ticket; the tables are here. Trade shows the Open positions and Pending orders tables; point at a position to close it or move its stop to the entry, and Close all / Cancel all ask once more. History sums up the closed trades (net profit, win rate, profit factor, best and worst) above the table, with one-click periods and Trades / Orders / Deals views. Report holds the full statistics, and Journal tells the session as plain lines, newest first. Every order is its own position (hedging): a second buy does not merge into the first, and a sell does not reduce a buy — each one closes on its own. Automated strategy runs keep one net position per symbol, as their rules expect.

Shortcuts

  • F9 — quick market order at the current price.
  • Ctrl+1 … Ctrl+6 — switch toolbox tabs.
  • Ctrl+K — search, J — journal, Ctrl+Alt+J — export journal.

Shortcuts never fire while your cursor is inside a text field.