CORE-10504 #resolve
[APPS]: Use again just the conutils library.
The effect of these two modifications above is to partly revert r73024 (the code splitting remains on the contrary).
[CMAKE]: Remove the "evil workaround" (revert r73027). See CORE-12206 for more details.
svn path=/trunk/; revision=73110
- Fix FormatMessage flags sanitization.
- Use "LANG_USER_DEFAULT" instead of MAKELANGID(LANG_NEUTRAL, SUBLANG_DEFAULT) (these are the same, but one is shorter than the other).
- In case LookupAccountSidW fails to retrieve the user name of an associated SID, use ConvertSidToStringSidW to get the SID string directly and display it, instead of claiming there is no associated user for a given event.
- In addition to display (in the status bar) the number of events in the selected log, display the number of events actually listed. This can be useful when events filtering will be completely implemented, and it can be also useful for detecting possible corrupted logs where the number of enumerable events is different (less) than the total number of events in the log...
==> To translators: please update the translations!
CORE-11637
svn path=/trunk/; revision=73043
Finally merge my branch "colins-printing-for-freedom", giving us an initial implementation of a Win32-compatible Printing Stack (localmon, localspl, spoolss, spoolsv, winspool)
You can now send raw data to parallel port printers using documented Win32 API. An example application is in my "winspool_print" commandline tool merged to rosapps.
ReactOS folks, thanks for your support during the development of this, making my bachelor's thesis a reality! :)
Documentation/Thesis: https://svn.reactos.org/reactos/trunk/documentation/articles/Printing%20Stack%20Thesis/thesis.pdf
Video: https://www.youtube.com/watch?v=cNzePucTOLY
CORE-10489
svn path=/trunk/; revision=73039
[EVENTLOG]: Make usage of this library.
CORE-11868 #resolve #comment Committed in r73035.
[EVENTLOG]: Protect the global handle table with a lock as it seems to me that this needs serialization. Please notify me if you think this is not actually necessary (and I'll revert that in case).
svn path=/trunk/; revision=73035
- Update code source files headers.
- Use explicit unicode functions for RegOpen/Query/SetXXX and safe-string APIs.
- Use GetSystemWindowsDirectoryW where needed instead of GetWindowsDirectoryW (TS-safe).
- Fix some variable names & types.
- Improve some DPRINTs.
svn path=/trunk/; revision=73034
- When displaying files, display the percentage of file read so far in the "Continue" prompt. Otherwise (when being piped or feeded from StdIn), just display the "Continue" prompt without percentage.
- Try to detect the text file encoding (ANSI, UTF16-BE/BE w/ or w/o BOM; UTF-8 to do!!) before displaying it. See the code for more details.
NOTE that the other functionalities of more (being able to scroll one line at a time, other command-line switches, etc...) are still not implemented yet.
svn path=/trunk/; revision=73025
- Introduce new functionalities related to console streams, a console screen management api (almost stubbed), a console pager api (adapted from code from CMD). This new functionality will be used in the future. See CORE-10504 for more details.
- As this library is therefore growing up, split it in small parts (sublibraries) that can be used, with the following dependency scheme: base utils (standalone); streams depending on base; screen depending on streams; pager depending on screen.
[APPS]: As a result, modify the CMakeLists of the different apps that use conutils to make them depend on the correct sublibrary.
svn path=/trunk/; revision=73024
- Localization of output based on a patch by Lee Schroeder, but where I haven't modified yet the output localization of errors.
- Dynamically underline the headers of the device status reports (by me).
CORE-12178
svn path=/trunk/; revision=72996
- Rearrange ResizeTextConsole so that it correctly computes the Top & Bottom parts of the window size rectangle;
- Fix its return type;
- Display an error if we failed resizing the console;
- Clear the screen before resizing the console, as the real MODE.COM does.
- Fix a parsing error in SetConsoleStateOld and in SetConsoleCPState.
svn path=/trunk/; revision=72995
- Parse the command line the same peculiar way as Windows' mode.com tool. This is certainly done such as to be backwards-compatible with MS-DOS' tool.
- Fix serial port string parsing, based on Wine's dll/win32/kernel32/wine/comm.c code. Note that the BuildCommDCB kernel32 API has the same syntax :)
- Implement support for MODE CON codepage, as well as screen size and typematic settings. Screen size code is based on NTVDM's one and will be subject to fixes later on.
MISSING stuff:
- LPT/COM port redirection.
- Localization :)
CORE-12176 #resolve
CORE-7998 CORE-8001
svn path=/trunk/; revision=72980
- fix an odd quirk that resulted from Paint setting wallpaper and wallpaper style in the wrong order
- add the flag SPIF_SENDWININICHANGE
Setting wallpapers now works, whenever the OS natively supports the respective file format for wallpapers.
svn path=/trunk/; revision=72972
- Improve the screen pager so that it looks a bit more like MORE's one: display full screen pages, where only the last line contains the "press any key..." prompt, and erase this prompt when a key is pressed and before displaying the other screen page.
- GetScreenSize parameters are pointers (so use NULL instead of 0);
- Use ARRAYSIZE instead of hardcoding buffer number of elements;
- Simplify PrintInfoLine() (use read-only resource string buffer returned by LoadString instead of a temporary buffer, since we are just interested in the counted string).
svn path=/trunk/; revision=72955
- Fix typo in STRING_MEMMORY_xxx symbols (memmory -> memory);
- Remove the trailing newline for the STRING_MISC_HELP1 page prompt, as part of reworking it a bit (see next commit);
- Code formatting in type.c as I'll touch it after.
svn path=/trunk/; revision=72954
- Use a dynamic-allocated buffer with FormatMessageW, fixes messages disappearance (eg. ping help in russian). CORE-12108 #comment Fixed in r72943.
- Remove the unneeded 1-line function "Usage" and instead just directly call the corresponding PrintString function.
svn path=/trunk/; revision=72943
Make those command tools use the console uilities library, aka. solve all those problems of wrong characters on the console...
CORE-10584 #resolve
[CONUTILS]: Remove the now unneeded compatibility defines.
CORE-10504
svn path=/trunk/; revision=72933
- Use Puts functions where needed;
- Fix a __stdcall that needs to be read __cdecl for a variadic function.
[CACLS]
Fix some resources so that the strings can hold on the width of a standard console screen (80 chars).
svn path=/trunk/; revision=72930
Make those command tools use the console uilities library, aka. solve all those problems of wrong characters on the console...
Nitpickers may notice that at some places, the usage of a "Puts"-like function would be better than Printf. Don't worry, I'm on it, it's for another commit.
CORE-10504
CORE-11909 #resolve
svn path=/trunk/; revision=72928