mirror of
git://git.savannah.nongnu.org/eliot.git
synced 2025-01-28 19:58:35 +01:00
- Always display characters in uppercase on the board (a lowercase character was still possible with a joker, in some rare cases)
- Fixed a compilation warning
This commit is contained in:
parent
a8b842a1a7
commit
8f72fd8152
2 changed files with 3 additions and 3 deletions
|
@ -123,7 +123,7 @@ void BoardWidget::paintEvent(QPaintEvent *)
|
|||
// Draw the letter
|
||||
if (m_game != NULL && !m_game->getBoard().getTile(row, col).isEmpty())
|
||||
{
|
||||
wchar_t chr = m_game->getBoard().getTile(row, col).toChar();
|
||||
wchar_t chr = towupper(m_game->getBoard().getTile(row, col).toChar());
|
||||
if (m_game->getBoard().getCharAttr(row, col) & ATTR_JOKER)
|
||||
painter.setPen(JokerColour);
|
||||
painter.setFont(letterFont);
|
||||
|
|
|
@ -95,10 +95,10 @@ void Box::printDataLine(int n, int x, const char *fmt, ...) const
|
|||
va_list vl_args;
|
||||
char *buf = NULL;
|
||||
va_start(vl_args, fmt);
|
||||
vasprintf(&buf, fmt, vl_args);
|
||||
int res = vasprintf(&buf, fmt, vl_args);
|
||||
va_end(vl_args);
|
||||
|
||||
if (buf == NULL)
|
||||
if (buf == NULL || res == -1)
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue