試試.,,不知道和你想要的有沒有一樣
- inputs:
- ShowPriceLine( True ),
- LineColor( DarkGray ),
- LineStyle( Tool_Dashed3 ),
- ShowText( True ),
- TextColor( RGB(255,104,32) ),
- TextSize( 14 ),
- TextShiftUp( 2 ) ;
- variables:
- TL_ID( 0 ),
- int NumDecimals( 0 ),
- Date_And_Time(0),
- TheHigh(0),
- Text_ID( 0 ) ;
- {
- if Category = 12 then
- NumDecimals = Log( PriceScale ) / Log( 10 ) - 1
- else
- NumDecimals = Log( PriceScale ) / Log( 10 ) ;
- }
- if Date=1170509 and time=1315 and ShowPriceLine then begin
- TheHigh= H;
- TL_ID = TL_New( D, T, H, D, T, H ) ;
- TL_SetColor( TL_ID, LineColor ) ;
- TL_SetStyle( TL_ID, LineStyle ) ;
- TL_SetSize( TL_ID, 0 ) ;
- TL_SetExtRight( TL_ID, True ) ;
- TL_SetExtLeft( TL_ID, false ) ;
- TL_SetColor( TL_ID, LineColor ) ;
- Date_And_Time = getappinfo(aiRightDispDateTime);
- Text_ID = Text_New( D, T, H, NumToStr( H, NumDecimals ) ) ;
- if ShowText then begin
- Text_SetLocation( Text_ID, D, T, H+ TextShiftUp ) ;
- Text_SetColor( Text_ID, TextColor ) ;
- Text_SetSize( Text_ID, TextSize ) ;
- Text_SetString( Text_ID, Spaces( 0 ) + NumToStr( C, NumDecimals ) ) ;
- Text_SetStyle( Text_ID, 0, 1 ) ;
-
- end ;
- end ;
- Date_And_Time = getappinfo(aiRightDispDateTime);
- text_setLocation(Text_ID,JulianToDate(IntPortion(Date_And_Time)),datetime2eltime(Date_And_Time)-60,TheHigh);
-
-
-
複製代碼
|