Browsed by
Month: June 2015

Mouse Buttons in Win32

Mouse Buttons in Win32

To respond to special mouse button actions in Win32, we need to register the virtual command actions with the callback loop to detect the special mouse button action. For example, to detect forward and backward mouse button actions, we register the APPCOMMAND_BROWSER_FORWARD and APPCOMMAND_BROWSER_BACKWARD events: Should the WM_APPCOMMAND options not work, you might want to look into the VK_* event codes.

Reading wide characters with wifstream

Reading wide characters with wifstream

Should we want to use wifstream to read unicode characters directly from a file, we will encounter an implementation quirk with newline detection in the standard library. Carriage returns and line feed (CR/LF) characters contained within certain characters as a part of a character’s unicode encoding can be mistaken by std::getline for the newline character. This mix-up then causes std::getline to split lines of text in half. wifstream provides a unicode wide character interface to the std library’s file operation…

Read More Read More

WordPress Updates asks for FTP Credentials

WordPress Updates asks for FTP Credentials

When attempting to run wordpress updates, wordpress can ask for ftp credentials. This can be caused by a conflict between the user/group ownership of the wordpress installation’s files and the webserver’s user credentials. The easiest way to fix this is to match the file ownership with the webserver’s user account: