MMPrice THV_v1

Download script
MMPrice THV_v1

This tool is designed to provide a clear, real-time visual display of the current market price directly on your trading chart. Instead of constantly looking at the complex price scales on the side of the screen, this script places a large, easy-to-read label in a specific corner of your workspace that updates instantly as the market moves.

Key Features and Logic:

Dynamic Price Tracking The script continuously monitors the "Bid" price (the current selling price) of the currency pair you are trading. It automatically detects the correct number of decimal places based on the asset type; for example, it recognizes the difference between standard pairs (typically 4 decimals) and Japanese Yen pairs (typically 2 decimals), ensuring the price always looks accurate and consistent.

Visual Momentum Cues One of the primary functions of this tool is its ability to change colors based on market movement. If you enable the automatic color feature, the text will change dynamically:

  • Green: The price has moved upward compared to the previous update.
  • Red: The price has moved downward compared to the previous update. This allows you to instantly perceive the "heartbeat" of the market—whether the trend is pushing up or down—without having to analyze individual price points.

Fully Customizable Display The tool is designed to be integrated into your personal trading layout seamlessly. You can customize how the information appears using several settings:

  • Positioning: Choose which corner of the chart the price should appear in (e.g., top right, bottom left, etc.).
  • Typography: You can adjust the font type (such as Arial Black) and the size to ensure it is visible enough for your specific screen setup.
  • Color Preferences: While the script can change colors automatically to show movement, you can also set a default static color for the display.

In essence, this script acts as a high-visibility dashboard element, turning raw market data into a clear, color-coded visual signal that helps you keep a closer eye on price action at a glance.

16 Views
1 Downloads
0 Favorites
MMPrice THV_v1
//+------------------------------------------------------------------+
//| Magnified Market Price.mq4        ver1.4             by Habeeb   |
//| Modified by FerruFX for Cobraforex THV System, www.cobraforex.com|
//+------------------------------------------------------------------+
#property indicator_chart_window
//----
  extern string note1="Change font colors automatically? True = Yes";
  extern bool   Bid_Ask_Colors=True;
  extern string note2="Default Font Color";
  extern color  FontColor=Black;
  extern string note3="Font Size";
  extern int    FontSize=32;
  extern string note4="Font Type";
  extern string FontType="Arial Black";
  extern string note5="Display the price in what corner?";
  extern string note6="Upper left=0; Upper right=1";
  extern string note7="Lower left=2; Lower right=3";
  extern int    WhatCorner=1;
//----
  double        Old_Price;
//+------------------------------------------------------------------+
//|                                                                  |
//+------------------------------------------------------------------+
int init()
  {
   return(0);
  }
//+------------------------------------------------------------------+
//|                                                                  |
//+------------------------------------------------------------------+
int deinit()
  {
   ObjectDelete("Market_Price_Label");
//----
   return(0);
  }
//+------------------------------------------------------------------+
//|                                                                  |
//+------------------------------------------------------------------+
int start()
  {
   if (Bid_Ask_Colors==True)
     {
      if (Bid > Old_Price) FontColor=LawnGreen;
      if (Bid < Old_Price) FontColor=Red;
      Old_Price=Bid;
     }
     
   //---- Define the standard digits
   int digits;
   string sub=StringSubstr(Symbol(), 3, 3);
   if(sub == "JPY") digits = 2;
   else digits = 4;
    
   string Market_Price=DoubleToStr(Bid, digits);
//----   
   ObjectCreate("Market_Price_Label", OBJ_LABEL, 0, 0, 0);
   ObjectSetText("Market_Price_Label", Market_Price, FontSize, FontType, FontColor);
   ObjectSet("Market_Price_Label", OBJPROP_CORNER, WhatCorner);
   ObjectSet("Market_Price_Label", OBJPROP_XDISTANCE, 1);
   ObjectSet("Market_Price_Label", OBJPROP_YDISTANCE, 1);
  }
//+------------------------------------------------------------------+

Comments