Changeset 515 for trunk/Packages/DpiControls
- Timestamp:
- Jan 3, 2024, 4:53:46 PM (11 months ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Packages/DpiControls/Dpi.Common.pas
r514 r515 185 185 DstWidth, DstHeight: Integer; 186 186 SrcWidth, SrcHeight: Integer; 187 ReduceWidth, ReduceHeight: Integer;188 187 begin 189 188 {$IFDEF WINDOWS} … … 198 197 SrcWidth := ScaleToNativeDist(XSrc, Width); 199 198 SrcHeight := ScaleToNativeDist(YSrc, Height); 200 if (Frac(ScaleFloatToNative(XSrc)) > 0) or201 (Frac(ScaleFloatToNative(X)) > 0) then ReduceWidth := 1202 else ReduceWidth := 0;203 if (Frac(ScaleFloatToNative(YSrc)) > 0) or204 (Frac(ScaleFloatToNative(Y)) > 0) then ReduceHeight := 1205 else ReduceHeight := 0;206 199 if (DstWidth = SrcWidth) and (DstHeight = SrcHeight) then begin 207 200 Result := LCLIntf.BitBlt(DestDC, ScaleToNative(X), ScaleToNative(Y), … … 210 203 end else begin 211 204 Result := LCLIntf.BitBlt(DestDC, ScaleToNative(X), ScaleToNative(Y), 212 DstWidth - ReduceWidth, DstHeight - ReduceHeight, SrcDC,205 SrcWidth, SrcHeight, SrcDC, 213 206 ScaleToNative(XSrc), ScaleToNative(YSrc), Rop); 214 207 … … 224 217 ScaleToNative(XSrc), ScaleToNative(YSrc) + SrcHeight - (DstHeight - SrcHeight), Rop); 225 218 end; 226 227 219 { Result := LCLIntf.StretchBlt(DestDC, ScaleToNative(X), ScaleToNative(Y), 228 220 DstWidth, DstHeight, SrcDC,
Note:
See TracChangeset
for help on using the changeset viewer.