aboutsummaryrefslogtreecommitdiffhomepage
path: root/win32/PlatWin.cxx
AgeCommit message (Collapse)AuthorFilesLines
2020-07-29Backport: Use dynamic_cast for SurfaceGDI::Copy as it will fail better if a ↵Neil1-1/+1
mistake made. Backport of changeset 8464:73514a371867.
2020-07-28Backport: Fix factory leak by using global factory instead of getting from ↵Neil1-4/+1
render target. Backport of changeset 8461:3626579329d1.
2020-07-27Backport: Add private SurfaceD2D::GetBitmap to better encapsulate the bitmap ↵Neil1-8/+11
render target and simplify callers. Backport of changeset 8460:6e7bbeda1f5a.
2020-07-15Backport: Hoist common conversion code into RectangleFromPRectangle.Neil1-4/+12
Backport of changeset 8405:004e2fe0cc50.
2020-07-15Backport: Add extra checking and assertions for NULLs.Neil1-30/+34
Use ReleaseUnknown which is noexcept making it easier to reason about exceptions. Add constexpr where possible. Backport of changeset 8403:0c52875b4c8c.
2020-07-11Backport: Removed GetNearestColor as paletted displays are no longer supported.Neil1-3/+1
Backport of changeset 8397:c1ad4413f156.
2020-06-15Backport: Use ReleaseUnknown to extend noexcept over finalisation.Zufu Liu1-22/+9
Backport of changeset 8305:986abc429f9a.
2020-06-11Backport: Bug [#2185]. Fix printing to use correct text size.Neil1-1/+3
Backport of changeset 8301:b006d175ac85.
2020-06-06Backport: Implement gradients for GDI. GradientRectangle previously drew an ↵Neil1-5/+60
average of the first two stops over the whole rectangle. Backport of changeset 8291:41857e0d7b3a.
2020-06-06Backport: Add DIBSection class to simplify bitmap operations on GDI.Neil1-66/+121
Backport of changeset 8290:7d93501a4443.
2020-06-06Backport: Avoid type-pun union when converting from RGBA colour to DWORD as ↵Neil1-13/+9
this may be undefined or implementation defined behaviour. Drop some casts by hoisting out part of dwordMultiplied. Backport of changeset 8289:a53064f376c5.
2020-06-06Backport: Specify locally visible methods as noexcept.Neil1-20/+20
Backport of changeset 8288:8b00e43e66b2.
2020-06-06Backport: Prefer .data() over &[0] as more explicit.Neil1-2/+2
Backport of changeset 8287:f8749b773e12, but without C++17 and C++20 features.
2020-06-06Backport: Add ReleaseUnknown to safely release IUnknown* and avoid warnings ↵Neil1-8/+3
when done in noexcept context. Backport of changeset 8286:bddda9b7df4f.
2020-06-06Backport: Bug [#2063]. On Windows 8.1 where GetDpiForWindow is not ↵Zufu Liu1-0/+23
available, use GetDpiForMonitor to emulate it. Backport of changeset 8285:426f23226f0d.
2020-05-28Backport: Bug [#2063]. Call AdjustWindowRectExForDpi when available to find ↵Zufu Liu1-8/+16
correct size. Backport of changeset 8267:5899b54cc783.
2020-05-27Backport: Bug [#2063]. Make reverse arrow cursor scale with DPI.Zufu Liu1-9/+21
Backport of changeset 8265:01940b16fb7e.
2020-05-27Backport: Bug [#2063]. Add SystemMetricsForDpi and use for ListBox and mouse ↵Zufu Liu1-10/+36
drag and drop. Simplify IME font definition. Backport of changeset 8264:2dd165934cbb.
2020-05-20Backport: Fix some minor warnings.Neil1-8/+7
Backport of changeset 8246:2cb0e52ada52.
2020-05-19Backport: Bug [#2171]. Implement per-monitor DPI Awareness on Windows.Neil1-21/+38
Backport of changeset 8244:134a3860b01e.
2020-06-17Backport: Encapsulate GetProcAddress in a way that avoids undefined and ↵mitchell1-26/+22
conditionally defined behaviour. Backport of changeset 8243:09cccd3f867b.
2020-04-05Backport: Feature [feature-requests:1345]. Use ListBox_ macros in preference ↵Neil1-10/+10
to LB_ messages. Modify types to match. Backport of changeset 8111:d15f7fe3467b.
2020-04-05Backport: Feature [feature-requests:1345] Use more typesafe code to clear ↵Neil1-4/+4
window pointers, share implementation of window pointers between files, use GetWindowStyle. Backport of changeset 8110:33f16ac2c3ca.
2020-03-26Backport: Fix spelling mistakes.Neil1-2/+2
Backport of changeset 8028:78a688809e75.
2020-03-25Backport: Replace const with constexpr where possible.Neil1-10/+6
Backport of changeset 8026:3d47c097aa3f.
2020-03-17Backport: Remove CRITICAL_SECTION by creating reverse arrow cursor at ↵Neil1-30/+17
initialization. InitializeCriticalSection inside DllMain can cause exceptions on old Windows. Backport of changeset 8009:ef650c1aa3ca.
2020-02-15Backport: Extract image conversion from RGBA to BGRA premultiplied into ↵Neil1-21/+6
common function. Backport of changeset 7987:beeac488af4d.
2020-02-15Backport: Bug [#2138]. For pixmap, balance call to BeginDraw with EndDraw.Neil1-0/+2
This avoids a warning when Direct2D debugging turned on. Backport of changeset 7986:8c409393be53.
2020-03-27Backport: Use dynamic_cast and assertion instead of static_cast to fail ↵mitchell1-13/+20
earlier if there is a bug. Backport of changeset 7984:0f23c38fa1ac.
2020-02-09Backport: Use uniform initialization for resetting GDI handles to avoid ↵Neil1-20/+20
NULL/0 warnings. Changed HDC, HPEN, HBRUSH, HFONT, HRGN, and HBITMAP. Backport of changeset 7980:587c0b6a5317.
2020-02-09Backport: Feature [feature-requests:#1340] Move and use Point functions to ↵Zufu Liu1-4/+4
avoid casting. Backport of changeset 7976:4ba647207671.
2020-01-31Backport: Avoid Clang warning with extra test.Neil1-5/+5
Harmonize types to avoid casts. Backport of changeset 7967:ddf1b734e7f8.
2020-01-31Backport: Use more typesafe functions to remove casts.Neil1-13/+5
Backport of changeset 7966:2f6615753946.
2020-01-06More synchronizing LongTerm3 with default.mitchell1-1/+2
Ideally this covers anything missed during the backport process.
2020-01-03Backport: Use safe mechanism for converting between function pointers and void*.mitchell1-7/+6
Backport of changeset 7863:507307a6c315.
2020-01-03Fixed a build error on Windows introduced by r7280 (changeset 9cf6a15d6c85).mitchell1-0/+6
2019-12-29Backport: Move suppression of Clang warning language-extension-token from ↵Neil1-0/+5
makefile to only C++ file that requires it. Backport of changeset 7844:bb2bc0e7f17a.
2019-12-03Backport: Bug [#2144]. Fixed drawing of translucent rounded rectangles with ↵Neil1-1/+1
Direct2D. Backport of changeset 7782:da8db8ba734d.
2019-11-21Backport: Make reference argument const as safe to do so.Neil1-4/+4
Backport of changeset 7771:7935a8d953e5.
2019-05-29Backport: Bug [#2104]. Use 'l' long format length sub-specifier for HRESULT ↵Neil1-1/+1
as it is long. Backport of changeset 7539:b22c2d7b0301.
2019-05-11Backport: Feature [feature-requests:#1283]. Standardise spelling - "color" ↵Neil1-7/+7
-> "colour". Backport of changeset 7498:7dd63f4402ae.
2019-05-08Backport: Use value-initialization and nullptr (for true pointers) to avoid ↵Neil1-10/+5
'using NULL' warnings. Backport of changeset 7493:614a823a36cb.
2019-04-28Backport: Use const and noexcept for private methods.Neil1-6/+6
Backport of changeset 7485:3c487fc19b62.
2019-04-27Backport: Feature [feature-requests:#1279]. Removed invalid check when ↵Neil1-12/+7
avoiding SelectFont if font not changed. Didn't correct the check as its not justified by minimal performance benefit so removed the supporting variable. Backport of changeset 7474:6bb2a6d284d9.
2019-04-12Backport: Bug [#2093]. Improve efficiency with single byte character sets.Zufu Liu1-2/+2
Backport of changeset 7424:0d4b29e058f7.
2019-04-11Backport: Feature [feature-requests:#1277]. Support coloured text on Windows ↵Zufu Liu1-3/+15
8.1+. Backport of changeset 7419:76fcbb9c97a1.
2019-03-25Backport: Use generic std::abs instead of abs and fabs.Neil1-5/+5
Backport of changeset 7330:09e5fe965a79.
2019-03-31Backport: Use generic versions of ceil, floor, round, lround, trunc from ↵mitchell1-15/+15
<cmath>. Backport of changeset 7329:2662ef098d93, but without std::round and std::lround, since older Mac OSX SDKs may not have them.
2019-03-20Backport: Implement WStringFromUTF8 to simplify code that creates wstring ↵Neil1-4/+2
objects for regular expressions and calling the Win32 API. Backport of changeset 7325:6148329fb2f3, but replaced std::string_view usage with const char* and size_t components. Also used #ifdef instead of C++17 `if constexpr` at suggestion of Neil.
2019-03-18Backport: Add some operators to Point to simplify client code.Neil1-3/+1
Backport of changeset 7321:d488340e94c0.