//+------------------------------------------------------------------+
//| Magnified Market Price.mq4        ver1.4             by Habeeb   |
//+------------------------------------------------------------------+
//|                                       Magnified price object.mq4 |
//+------------------------------------------------------------------+
//| Zoom Price.mq4                                                   | 
//|                               rounding Price of 6 decimal broker |
//|                   combine 3 style by Cmkm-2011- thhudu@yahoo.com | 
//+------------------------------------------------------------------+
#property copyright "combine 3 style by Cmkm-2011- thhudu@yahoo.com" 
#property indicator_chart_window
//----
  extern color      ObjectColor    = LawnGreen;

extern bool _________________Corner = true;
  extern int    FontSize=18;
  extern int    WhatCorner`1`2`3`4=1;
  string FontType="Comic Sans MS";
extern bool _______________Moving_Text = false;
  extern int    Size_Text = 14;
  extern int    Clearance_Text  = 35;
extern bool _______________Moving_Box  = false;
  extern int    Size_Box = 2;
  extern int    Clearance_Box  = 18;

datetime    objtime; 
bool normalize = true; //If true then the spread is normalized to traditional pips
double Poin;
int n = 0;
//+--------------------------------------+
int init()

  {IndicatorShortName("Zoom Price | ");
  
   //Checking for unconvetional Point digits number
   if (Point == 0.00001) Poin = 0.0001; //5 digits
   else if (Point == 0.001) Poin = 0.01; //3 digits
   else Poin = Point; //Normal

   if ((Poin > Point) && (normalize))  // 6 decimal broker
   {      n = 1;   }
   return(0);
  }
//+--------------------------------------+

int deinit()
  {
   ObjectDelete("Price_Corner");
   ObjectDelete("Price_A");
   ObjectDelete("Price_B");

   return(0);
  }
//+--------------------------------------+

int start()
  {
   string Market_Price=DoubleToStr(Bid, Digits-n);//DoubleToStr(Bid, Digits);

//+--------------------------------------+

  if (_________________Corner == true) { // on/off show (only this line)
   
   ObjectCreate("Price_Corner", OBJ_LABEL, 0, 0, 0);
   ObjectSetText("Price_Corner", Market_Price, FontSize, FontType, ObjectColor);
   ObjectSet("Price_Corner", OBJPROP_CORNER, WhatCorner`1`2`3`4);
   ObjectSet("Price_Corner", OBJPROP_XDISTANCE, 1);
   ObjectSet("Price_Corner", OBJPROP_YDISTANCE, 1);
                                  }
//+--------------------------------------+

  if (_______________Moving_Text == true) { // on/off show (only this line)

      objtime = Time[0] + Period()*60*Clearance_Text;
      if(ObjectFind("Price_A") != 0)
      ObjectCreate ("Price_A", OBJ_TEXT, 0, objtime , Bid);
      ObjectSetText("Price_A", "<-" + Market_Price, Size_Text, FontType, ObjectColor);
                                    }
      else{
      ObjectMove("Price_A", 0,objtime , Bid); }
//+-------------------------------------------+

  if(_______________Moving_Box == true){  // on/off show  (only this line)
      
    objtime = Time[0] + Period()*60*Clearance_Box;
  
    ObjectCreate("Price_B",OBJ_ARROW,0,objtime,Bid);
    ObjectSet("Price_B",OBJPROP_ARROWCODE,6);
    ObjectSet("Price_B",OBJPROP_COLOR,ObjectColor);
    ObjectSet("Price_B",OBJPROP_WIDTH,Size_Box);
   
    ObjectMove("Price_B",0,objtime,Bid);     }
  
//+-------------------------------------------+
return(0);
     }