Commit graph

1478 commits

Author SHA1 Message Date
Katayama Hirofumi MZ
c876fe350d
[IMM32][NTUSER] Strictly check Cicero IME (#8009)
This PR enhances Cicero IME support.
JIRA issue: CORE-19268
- Add null checks for the functions
  of Cicero IMEs in Imm32LoadIME
  function.
- Add and use
  IS_CICERO_COMPAT_DISABLED
  macro in win32ss/include/ntuser.h.
- Fix ImmGetImeInfoEx,
  Imm32LoadImeDpi,
  ImmGetDescriptionA,
  ImmGetDescriptionW,
  ImmGetIMEFileNameA,
  ImmGetIMEFileNameW, and
  ImmGetProperty functions for
  Cicero IME support.
- Set last error in NtUserGetImeInfoEx.
2025-05-20 07:34:46 +09:00
Katayama Hirofumi MZ
9e1f2b035f
[NTUSER][USER32] Rewrite GetAncestor (#7978)
JIRA issue: N/A
- Set the last error.
- Check message window.
- Modify user32.spec.
2025-05-16 19:41:01 +09:00
Hervé Poussineau
49427c48c5 [WIN32SS:USER] If default display driver doesn't work, try with VGA
CORE-7728, CORE-16002, CORE-16009, CORE-19224, CORE-19951
2025-05-12 18:24:58 +02:00
Hervé Poussineau
dca369cf41 [WIN32SS:ENG] Rework EngpUpdateGraphicsDeviceList
- choose VGA adapter outside of driver initialization loop
- choose primary adapter outside of driver initialization loop
- link VGA adapter to primary adapter at the end
- only set DISPLAY_DEVICE_PRIMARY_DEVICE in this function

Also mark VgaSave driver as SystemStart instead of Disabled,
so it is available if main display driver doesn't work.
2025-05-12 18:24:55 +02:00
Hervé Poussineau
3729b96625 [WIN32SS:ENG] In case of error, display the name of the problematic file 2025-05-08 21:48:14 +02:00
Hervé Poussineau
a8abe1d677 [WIN32SS:ENG] Move debug log to the right place
Display number of prepared modes after preparing them, not at device creation
where this number is always 0.
2025-05-08 21:48:14 +02:00
Hervé Poussineau
a36bf31a0d [VGAMP] Correctly initialize interface before calling VideoPortInitialize 2025-05-08 21:48:14 +02:00
Katayama Hirofumi MZ
0ca6002b4f
[GDI32][NTGDI][SDK] Font/Text: Fix SAL2 annotations and const-ness (#7865)
I want to work in correct type info.
JIRA issue: CORE-17684
- Add and fix SAL2 annotations.
- Fix const-ness of function
  parameters.
- Delete needless type casts.
2025-05-06 15:13:04 +09:00
Katayama Hirofumi MZ
530d26a1f4
[NTGDI][NTUSER] Initial support of NtGdiRemoveFontResourceW (#7877)
Enable the users to delete fonts.
JIRA issue: CORE-17684
- Add IntDeleteRegFontEntry helper function.
- Add RegDeleteValueW and RegEnumValueW helper
  functions in win32ss/user/ntuser/misc/registry.c.
- Add some code to IntGdiRemoveFontResourceSingle
  function.
2025-05-06 12:38:54 +09:00
Whindmar Saksit
6829350af9
[SHELL32][NTUSER] Implement the SEE_MASK_HOTKEY/ICON/HMONITOR flags (#7947) 2025-05-03 16:08:58 +02:00
Doug Lyons
e98bba2535
[NTGDI:FREETYPE] Fix Fonts broken by opening VLC About (Retry of PR #4579) (#7952)
* Check is FontGDI->OriginalWeight > FontGDI->RequestWeight and if so, then return original weight.
* Do not handle FontGDI->OriginalWeight as a boolean. Use 'FontGDI->OriginalWeight = FW_DONTCARE;'.

CORE-17011
2025-05-01 17:44:10 -05:00
Katayama Hirofumi MZ
d722e70817
[SDK][USER32] Implement WM_IME_SYSTEM.IMS_SOFTKBDONOFF (#7950)
Supporting soft keyboard will improve IME
usability.
JIRA issue: CORE-19268
- Define IMS_SOFTKBDONOFF constant as
  0x13 in <immdev.h>.
- Implement
  WM_IME_SYSTEM.IMS_SOFTKBDONOFF
  message handling in ImeWnd_OnImeSystem.
2025-05-01 11:20:18 +09:00
Doug Lyons
85afe48c3e
[GDI32] Fix MSVC warning in SetDIBitsToDevice and simplify code. (#7919)
This is a very small revert of PR #5227 to simplify the code and eliminate an MSVC warning.
It was pointed out by Timo Kreuzer as probably not doing what I intended and he was correct.
I added this code in PR #5227 to try and correct some return values from SetDIBitsToDevice.
After testing with this new PR, there was no difference in the regression tests for either
1) gdi32:bitmap or 2) gdi32:SetDIBitsToDevice after deleting the code here and the MSVC warning was fixed.
2025-04-24 21:04:36 -05:00
Whindmar Saksit
7eb8535edf
[STOBJECT][NTUSER][ACCESS] Don't use a systray timer when not needed (#7917) 2025-04-24 21:27:36 +02:00
Whindmar Saksit
78e04c07b8
[USER32] Read the CoolSwitch settings from the registry (#7920) 2025-04-24 15:22:43 +02:00
Katayama Hirofumi MZ
94fc56c038
[COMCTL32][USER32] Edit: Don't unlock if unlocked on EM_SETHANDLE (#7886)
JIRA issue: CORE-18944
EDIT_EM_GetHandle unlocks the handle,
so the next EM_SETHANDLE handler
shouldn't unlock the unlocked text.
Don't unlock the handle when es->text
was NULL on EM_SETHANDLE
message handling.
2025-04-24 19:21:22 +09:00
Whindmar Saksit
5a10ec60be
[EXPLORER][BROWSEUI][SHLWAPI][BOOTDATA][WIN32K] Support AppKeys and more WM_APPCOMMANDs (#7879)
Implements a couple of extra commands in IShellBrowser and adds support for the AppKeys fallback registry key (used when the foreground application does not handle the command).
2025-04-18 18:35:30 +02:00
Timo Kreuzer
18fc5a1391 [USER32] Fix use of uninitialized variable 2025-04-11 07:24:44 +00:00
Hermès Bélusca-Maïto
111c8cc62a
[REACTOS] Usage improvements for some RtlFindMessage invocations (#6023)
Use `RT_MESSAGETABLE` and `MAKELANGID(LANG_NEUTRAL, SUBLANG_NEUTRAL)`
instead of hardcoding their values.
2025-04-08 20:19:54 +02:00
Katayama Hirofumi MZ
1e6e5529c6
[FREETYPE][FTFD][DOC] Update FreeType to 2.10.0 from 2.9 (#7786)
Modernize font engine modules.
JIRA issue: CORE-16084
- Update FreeType to 2.10.0 from 2.9.
- Delete useless files.
- Add technical notes (TechNote.txt) on freetype.
- DbgPrint became FT_Message.
2025-04-04 20:50:25 +09:00
Katayama Hirofumi MZ
7efab12e6f
[CMAKE] Introduce set_wine_module (Retry) (#7860)
Re-trial of #7800. Deleting __WINESRC__
hacks.
JIRA issue: CORE-5743
- Add sdk/cmake/set_wine_module.cmake.
- Load set_wine_module.cmake at
  top-level CMakeLists.txt.
- Use set_wine_module cmake function
  and delete __WINESRC__ as possible.
- Delete many include_directories.
2025-04-04 20:44:38 +09:00
Katayama Hirofumi MZ
1890ad20f8
[NTGDI][GDI32] AddFontResource: Support multiple files (#7833)
JIRA issue: CORE-17684
- Add HEAP_strdupA2W_buf and HEAP_strdupA2W_buf_free
  helper functions for quick string conversion.
- Optimize HEAP_... functions.
- Add IntConvertFontPaths helper function.
- Support multiple files in AddFontResource function.
- Add cFiles parameter to some internal font addition/
  removal functions.
- Half-implement NtGdiRemoveFontResourceW and
  RemoveFontResourceExW functions.
2025-04-04 19:30:18 +09:00
Timo Kreuzer
dca5194279 [FTFD] Fix malloc/realloc/free wrappers
On x64 malloc needs to return a 16 byte aligned buffer, the previous code used an 8 byte header, making the allocations unaligned. This is now fixed with an improved header structure.
Also simplify realloc a bit and make it handle Object == NULL.
2025-04-03 16:22:09 +00:00
Katayama Hirofumi MZ
3660920b7f
[GDI32][NTGDI][SDK] ExtTextOut: Fix some type problems (#7856)
JIRA issue: CORE-19898
- Modify NtGdiExtTextOutW prototype.
- Add const to some paramters.
- Make Count parameter unsigned.
- Delete needless type casts.
2025-04-02 20:30:47 +09:00
Katayama Hirofumi MZ
87cd66a577
[NTGDI:FREETYPE] IntExtTextOutW: Renaming variables (#7851)
JIRA issue: CORE-19898
This PR is simply trivial renaming.
In IntExtTextOutW function:
s/SurfObj/psoDest/
s/SourceGlyphSurf/psoGlyph/
s/HSourceGlyph/hbmGlyph/
s/bitSize/glyphSize/
2025-04-02 03:54:42 +09:00
Doug Lyons
13657fdb5b
[USER32][LIBPNG] Support PNG/Vista icons (Retry) (#7709)
CORE-18385
Retry of PR #7704

In USER32 change CMakeLists.txt to include libpng.
Improve libpng.spec to include additional needed defines.
Add code into mostly cursoricon.c to support PNG icons.

Co-authored-by: Katayama Hirofumi MZ <katayama.hirofumi.mz@gmail.com>
2025-03-31 12:55:53 -05:00
Hervé Poussineau
cfde03ec9b [VIDEOPRT] Write monitor EDID to registry
This will be used later by win32k to give only valid display modes
to user mode.
2025-03-28 23:10:42 +01:00
Mark Jansen
49c40a2941 [PROGMAN][MSPORTS][VFDLIB][CONSRV] Update resource encoding to be utf8 2025-03-26 16:39:43 +01:00
Katayama Hirofumi MZ
c930c8c464
[GDI32] Implement RemoveFontResourceExA (#7813)
JIRA issue: CORE-17684
2025-03-25 10:38:17 +09:00
Justin Miller
d7db8c9c80 [WIN32SS] Fix the extra VOID amendum to e7a9e7c 2025-03-24 21:32:41 +01:00
Justin Miller
b9b765038e [WIN32SS] Fix an added APIENTRY amendum to e7a9e7c 2025-03-24 21:27:57 +01:00
Justin Miller
e7a9e7ca3d
[SDK][WIN32SS] Prepare d3dkmt functions up to Windows Vista (#5612)
Prepare the d3dkmt APIs up to Vista RTM
Build the skeleton needed for having userspace components talk to a WDDM KMD driver

Co-authored-by: Mark Jansen <mark.jansen@reactos.org>
Co-authored-by: Hermès BÉLUSCA - MAÏTO <hermes.belusca-maito@reactos.org>
2025-03-24 21:21:09 +01:00
Katayama Hirofumi MZ
6a95219ed3
[REACTOS] Don't use DLL_WINE_PREATTACH macro (#7802)
Related to #7800. Reduce code dependency on Wine.
JIRA issue: CORE-5743
- Wrap DLL_WINE_PREATTACH usage by #ifndef
  __REACTOS__ and #endif.
- Undefine DLL_WINE_PREATTACH macro in
  sdk/include/xdk/winnt_old.h.
2025-03-22 08:04:55 +09:00
Katayama Hirofumi MZ
27bb510282
[FREETYPE] Fix WordPad ruler rendering (#7803)
Based on @Doug-Lyons's wordpad-ruler-fix-05.patch.
JIRA issue: CORE-19870
In IntRequestFontSize function, if lfWidth < 10, then
req.width = 0;.

Co-authored-by: Doug Lyons <douglyons@douglyons.com>
2025-03-21 08:52:20 +09:00
Doug Lyons
5c505d9a9b
[NTUSER] Handle window update region larger than the current window in clip region (#7731)
CORE-18206 CORE-18799 CORE-19371

Fixes infinite loop of:
  err: Message WM_PAINT count 1 Internal Paint Set? FALSE

The symptom appears in the following scenario (as reported in CORE-18799):

A program (game) runs at a small resolution (e.g. 640 x 480), but the
game window gets invalidated at a larger size (e.g. 1152 x 864 screen
resolution) before switching to the smaller (640 x 480) size.
Because of this, the window's update region is larger than the current
window so only the 640 x 480 region gets validated leaving the remaining
region invalid. This causes the recurring WM_PAINT messages because there
is no way to invalidate the remaining area.
2025-03-12 12:18:53 +01:00
Hermès Bélusca-Maïto
bc62c17a7f
[KERNEL32][NTDLL][NTOS][WIN32K] Fix and sync the exports for RtlUnwindEx and RtlVirtualUnwind (#7749) 2025-03-11 18:59:22 +01:00
Justin Miller
6dccccc2a3 [USER32_VISTA][USER32] Sync some parts with WINE-10.0 2025-03-09 04:07:55 -07:00
Justin Miller
245513e7ec [USER32_VISTA] Import input.c misc.c win.c from wine-10.0 2025-03-09 04:07:55 -07:00
Whindmar Saksit
acbadb9fba
[USER32] PrivateExtractIcons must return 0 for empty files (#7767)
This bug breaks the documented S_FALSE return value for SHDefExtractIconW when the icon is not found.
2025-03-08 13:34:23 +01:00
Hermès Bélusca-Maïto
468a9787d1
Revert "[USER32][LIBPNG] Support PNG/Vista icons (#7704)"
This reverts commit 7f4708479d.

- PR was still in review;
- Doug has commit access himself.
2025-02-07 15:20:05 +01:00
Doug Lyons
7f4708479d
[USER32][LIBPNG] Support PNG/Vista icons (#7704)
Add PNG (NT6/Vista+) support.
JIRA issue: CORE-18385
- Change libpng to add IMPORTLIB libpng.spec
  to allow linking to it in USER32.
- Add code into mostly cursoricon.c to support
  PNG icons.
2025-02-07 23:12:32 +09:00
Katayama Hirofumi MZ
22577aed85
[NTUSER][USER32] Support GetWindow.GW_ENABLEDPOPUP (#7700)
JIRA issue: CORE-6920
- Make the return value of
  NtUserCallHwnd a DWORD_PTR.
- Add DWP_GetEnabledPopup
  helper function in
  win32ss/user/ntuser/defwnd.c.
- Add code to NtUserCallHwnd for
  HWND_ROUTINE_DWP_GETENABLEDPOPUP.
- Add code to GetWindow for
  GW_ENABLEDPOPUP.
- Set last error in GetWindow and
  IntGetWindow.
2025-02-07 07:31:08 +09:00
Katayama Hirofumi MZ
2f23e70ad5
Revert "[NTUSER] Enable SM_CXICON etc. settings from registry (#7679)" (#7682)
This reverts commit 3b3741c10a of #7679 .
It seems like the shell icon size is not the
system icon size.

The wide string L"Shell Small Icon Size" is detected in
shell32.dll and themeui.dll.
No L"Shell Small Icon Size" in win32k.sys found.
JIRA issue: CORE-12905
2025-01-29 21:34:19 +09:00
Katayama Hirofumi MZ
3b3741c10a
[NTUSER] Enable SM_CXICON etc. settings from registry (#7679)
Improve usability.
JIRA issue: CORE-12905
- Add nIconSize and nSmallIconSize
  values to SPIVALUES structure.
- Load "Shell Icon Size" and "Shell
  Small Icon Size" values from registry.
- Enable changing of SM_CXICON,
  SM_CYICON, SM_CXSMICON, and
  SM_CYSMICON settings.
2025-01-29 20:20:25 +09:00
Katayama Hirofumi MZ
fe11f7a2e5
[REACTOS] Refresh old URLs (#7632)
URLs are getting old. We have to
update URLs for documentation
purpose.
JIRA issue: CORE-19963
- Refresh old URLs.
- Add " (DEAD_LINK)" labels
  to dead links.
- Use MS Learn links rather
  than MSDN ones.
- Some dead links revived by
  Web Archive.
- Don't change Wine Tests
  and Wine Sync.
- Don't change 3rd party libraries.
- Don't append "redirected" labels.
2025-01-28 13:36:45 +09:00
Hermès Bélusca-Maïto
dbf784472e
[WIN32SS:NTGDI] FontFamilyFillInfo(): Check returned IntGetOutlineTextMetrics() size...
... before allocating pool memory, as it is done everywhere else in the code.
2025-01-23 23:20:54 +01:00
Hermès Bélusca-Maïto
07ce196d8e
[WIN32SS:NTGDI] Fix build, addendum to commit 9c474c4b7 2025-01-23 22:33:11 +01:00
Hermès Bélusca-Maïto
2e1a4e74a4
[WIN32SS:NTGDI] freetype.c: Fix the ordering of, and add some missing set-last-error calls. 2025-01-23 21:17:15 +01:00
Hermès Bélusca-Maïto
f22efba486
[WIN32SS:NTGDI] freetype.c: Use the correct last-error functions.
EngSetLastError() is for Win32 errors; SetLastNtError() is for NTSTATUS.
2025-01-23 21:03:26 +01:00
Hermès Bélusca-Maïto
c6cd3b242a
[WIN32SS:NTGDI] Improve a DPRINT 2025-01-23 20:51:18 +01:00