Changeset 89 for trunk/LocalPlayer/Help.pas
- Timestamp:
- Jan 19, 2017, 8:40:22 PM (8 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/LocalPlayer/Help.pas
r73 r89 205 205 SearchResult := THyperText.Create; 206 206 SearchResult.OwnsObjects := True; 207 sb := TPVScrollbar.Create ;208 sb.Set up(36, 9, 11, Self);207 sb := TPVScrollbar.Create(Self); 208 sb.SetBorderSpacing(36, 9, 11); 209 209 sb.OnUpdate := ScrollBarUpdate; 210 210 … … 268 268 procedure THelpDlg.OnScroll(var m: TMessage); 269 269 begin 270 { TODO: Handled by MouseWheel event 270 271 if sb.Process(m) then begin 271 272 Sel := -1; 272 273 SmartUpdateContent(true) 273 end 274 end; 275 } 274 276 end; 275 277 … … 294 296 s: string; 295 297 begin 296 s := MainText[sb. si.npos+ i];298 s := MainText[sb.Position + i]; 297 299 if s = '' then 298 300 exit; … … 304 306 y := y + WideFrame 305 307 end; 306 if THelpLineInfo(MainText.Objects[sb. si.npos+ i]).Format308 if THelpLineInfo(MainText.Objects[sb.Position + i]).Format 307 309 in [pkCaption, pkBigTer, pkRightIcon, pkBigFeature] then 308 310 begin … … 320 322 ca.Font.Assign(UniFont[ftNormal]); 321 323 end 322 else if THelpLineInfo(MainText.Objects[sb. si.npos+ i]).Format = pkSection324 else if THelpLineInfo(MainText.Objects[sb.Position + i]).Format = pkSection 323 325 then 324 326 begin … … 339 341 TextSize.cy := WideFrame + InnerHeight - y; 340 342 FillSeamless(ca, x, y, TextSize.cx, TextSize.cy, -SideFrame, 341 sb. si.npos* 24 - WideFrame, Paper);343 sb.Position * 24 - WideFrame, Paper); 342 344 end; 343 345 BiColorTextOut(ca, TextColor, $7F007F, x, y, s); … … 441 443 CaptionColor := Colors.Canvas.Pixels[clkMisc, cliPaperCaption]; 442 444 FillSeamless(OffScreen.Canvas, 0, 0, InnerWidth, InnerHeight, 0, 443 sb. si.npos* 24, Paper);445 sb.Position * 24, Paper); 444 446 with OffScreen.Canvas do 445 447 begin 446 448 Font.Assign(UniFont[ftNormal]); 447 for i := -sb. si.nposto InnerHeight div 24 do448 if sb. si.npos+ i < MainText.Count then449 for i := -sb.Position to InnerHeight div 24 do 450 if sb.Position + i < MainText.Count then 449 451 begin 450 HelpLineInfo := THelpLineInfo(MainText.Objects[sb. si.npos+ i]);452 HelpLineInfo := THelpLineInfo(MainText.Objects[sb.Position + i]); 451 453 if HelpLineInfo.Format = pkExternal then 452 454 begin … … 459 461 end; 460 462 for i := -2 to InnerHeight div 24 do 461 if (sb. si.npos + i >= 0) and (sb.si.npos+ i < MainText.Count) then463 if (sb.Position + i >= 0) and (sb.Position + i < MainText.Count) then 462 464 begin 463 HelpLineInfo := THelpLineInfo(MainText.Objects[sb. si.npos+ i]);465 HelpLineInfo := THelpLineInfo(MainText.Objects[sb.Position + i]); 464 466 if HelpLineInfo.Link <> 0 then 465 467 begin … … 1870 1872 HistKind[nHist - 1] := Kind; 1871 1873 HistNo[nHist - 1] := no; 1872 HistPos[nHist - 1] := sb. si.npos;1874 HistPos[nHist - 1] := sb.Position; 1873 1875 HistSearchContent[nHist - 1] := SearchContent 1874 1876 end … … 1888 1890 begin 1889 1891 y := y - WideFrame; 1890 i0 := sb. si.npos;1892 i0 := sb.Position; 1891 1893 Sel0 := Sel; 1892 1894 if (x >= SideFrame) and (x < SideFrame + InnerWidth) and (y >= 0) and … … 1911 1913 begin 1912 1914 if Sel >= 0 then 1913 with THelpLineInfo(MainText.Objects[Sel + sb. si.npos]) do1915 with THelpLineInfo(MainText.Objects[Sel + sb.Position]) do 1914 1916 if Link shr 8 and $3F = hkInternet then 1915 1917 case Link and $FF of
Note:
See TracChangeset
for help on using the changeset viewer.