Commit graph

1463 commits

Author SHA1 Message Date
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
Hermès Bélusca-Maïto
9c474c4b73
[WIN32SS:NTGDI] freetype.c: Use debug channel "GdiFont" 2025-01-23 20:25:25 +01:00
Hermès Bélusca-Maïto
e16dc27e47
[WIN32SS:ENG:GDI] bitblt(_new).c: Use correct debug channel "GdiBlt" 2025-01-23 20:23:30 +01:00
Katayama Hirofumi MZ
1868985dde
[FREETYPE][NTGDI] Simplify IntGdiLoadFontsFromMemory (#7651)
Simplify code logic and reduce management cost.
JIRA issue: CORE-19973
- Add IntGdiLoadFontByIndexFromMemory helper function.
- Simplify IntGdiLoadFontsFromMemory function.
2025-01-22 11:56:41 +09:00
Katayama Hirofumi MZ
bb7cf5a5b7
[FREETYPE][FTFD][NTGDI] Split FT_Bitmap_Convert hack (#7628)
Our FT_Bitmap_Convert function had a hack to make the
bitmap image compatible to ReactOS. I think the hack on
FT_Bitmap_Convert should be separated from our font
engine.
JIRA issue: CORE-16047
- Add FT_Bitmap_Convert_ReactOS_Hack function, that is
  based on FT_Bitmap_Convert, and split the hack of
  FT_Bitmap_Convert.
- Use FT_Bitmap_Convert_ReactOS_Hack in
  IntGetBitmapGlyphWithCache function instead of
  FT_Bitmap_Convert.
- Modify ftfd.spec to add 
  FT_Bitmap_Convert_ReactOS_Hack.
2025-01-22 10:57:40 +09:00
Katayama Hirofumi MZ
d4f283b67b
[FREETYPE][NTGDI] Use Face->num_faces instead of ttc_header.count (#7646)
Supporting raster fonts. Using
num_faces is the generic way.
JIRA issue: CORE-16165
- Use FT_FaceRec.num_faces instead
  of TT_Face.ttc_header.count in
  counting the font faces in
  IntGdiLoadFontsFromMemory function.
2025-01-20 22:09:16 +09:00
Katayama Hirofumi MZ
82b7d4f3da
[FREETYPE][NTGDI] Fix ftGdiGetTextMetricsW return for raster fonts (#7635)
Try to get ready to support raster fonts.
JIRA issue: CORE-17327
- Fix the return value of
  ftGdiGetTextMetricsW function
  for raster fonts.
2025-01-18 22:33:00 +09:00
Doug Lyons
b1257cefe1
[NTGDI] Silence some debug log spam from GreGetObjectOwner when input parameter is NULL. (#7606)
CORE-19962
Co-authored-by: Timo Kreuzer <timo.kreuzer@reactos.org>
2025-01-16 19:11:19 -06:00
Doug Lyons
1c55924045
[USER32_APTEST][USER32] CopyImage improve regression test and function. (#7524)
CORE-19806 and CORE-17902.

* Follow-up of PR #6886 and commit d3ec7cd to remove hack.
2024-12-24 17:51:31 -06:00
Hermès Bélusca-Maïto
cc3672cb73
[RESOURCES] Remove redundant #pragma code_page(), includes, etc.
They are redundant when these are already present in the given module's
root resource file, from which the language-specific resource files are
being included.
2024-12-22 18:39:26 +01:00
Timo Kreuzer
2d4c0b87b1 [WIN32K:NTUSER] Check for NULL desktop window in co_IntProcessMouseMessage 2024-12-22 10:19:01 +02:00
Ratin Gao
d936dba7ff [REACTOS] Fix 'seperate' typos 2024-12-11 08:56:06 +02:00
Hermès Bélusca-Maïto
01a10da73d
[VIDEOPRT] VideoPortInitialize(): Display the invalid and expected struct sizes on error 2024-12-09 13:42:44 +01:00
Timo Kreuzer
541cb0d9b2 [USER32] ordinals -> @ 2024-11-24 13:40:11 +02:00
Doug Lyons
3bb1e64408
[NTGDI:FREETYPE] Account for non-breaking spaces in x-dim of IntExtTextOutW (#7479)
CORE-19768
Follow up of PR #7274. This stop WARN's from FF 28 as well.

* Make del and nbsp const's based on reviewer comments.
2024-10-26 16:44:39 -05:00
Tomáš Veselý
cf955094b4
[NTUSER] IntSetTimer(): Use timer IDs range [256,32767] as on Windows (#7277)
Based on the Doug Lyons' test in #7087, I found that my previous fix stopped working partially. Or rather, it would only work until the 32767 indexes were exhausted. It seems to me that the behavior of the bitfield has changed, because when I published the previous patch, it passed my tests.

- Bit array generates free ID cyclically, in the previous code after 32767 indexes expired the same index was returned, because of this the previous fix would stop working after expiration, so change the logic of calculating the next index.
- Change the index range to 256-32767 to match Windows, indexes 0-255 can theoretically be used as reserved for system purposes.

Addendum to fd327db20f. CORE-9141
2024-10-22 18:10:34 +03:00