More updates to the Debian packaging for wxPython, unicode and
the project name change. Applied patch from ABX to make tex2rtf unicode compatible, then removed wxSprintf lameness from it so it might actually work. Also modified it to return true from tex2rtf OnInit in console builds so the app will exit with a successful return code rather than always returning failure even when it succeeds. Implemented unicode capable wxCtime for glibc systems also needed by tex2rtf. Wrapped dde include in tex2rtf in a guard and assert that dde is MSW only in its forwarding header. Lowered the limit of maxlen in wxSprintf so it actually has a chance to segfault on people instead of failing silently and mysteriously with glibc. Silenced some other 'potentially uninitialised variable' warnings from gcc3, most of which were bogus, one potentially not so. Added missing newline at the end of fontdlg.cpp. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@26094 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -6,7 +6,8 @@
|
||||
// reverse-engineering
|
||||
// and guesswork at its best.
|
||||
// Author: Petr Smilauer
|
||||
// Modified by:
|
||||
// Modified by: Wlodzimiez ABX Skiba 2003/2004 Unicode support
|
||||
// Ron Lee
|
||||
// Created: 01/01/99
|
||||
// RCS-ID: $Id$
|
||||
// Copyright: (c) Petr Smilauer
|
||||
@@ -116,10 +117,10 @@ bool SHGToMap(wxChar *filename, wxChar *defaultFile)
|
||||
HotSpot *hotspots = NULL;
|
||||
int n = ParseSHG(filename, &hotspots);
|
||||
if (n == 0)
|
||||
return FALSE;
|
||||
return false;
|
||||
|
||||
wxChar buf[100];
|
||||
wxSprintf(buf, _T("Converting .SHG file to HTML map file: there are %d hotspots in %s."), n, filename);
|
||||
wxSnprintf(buf, sizeof(buf), _T("Converting .SHG file to HTML map file: there are %d hotspots in %s."), n, filename);
|
||||
OnInform(buf);
|
||||
|
||||
wxChar outBuf[256];
|
||||
@@ -132,7 +133,7 @@ bool SHGToMap(wxChar *filename, wxChar *defaultFile)
|
||||
{
|
||||
OnError(_T("Could not open .map file for writing."));
|
||||
delete[] hotspots;
|
||||
return FALSE;
|
||||
return false;
|
||||
}
|
||||
|
||||
wxFprintf(fd, _T("default %s\n"), defaultFile);
|
||||
@@ -146,7 +147,7 @@ bool SHGToMap(wxChar *filename, wxChar *defaultFile)
|
||||
else
|
||||
{
|
||||
wxChar buf[300];
|
||||
wxSprintf(buf, _T("Warning: could not find hotspot reference %s"), hotspots[i].szHlpTopic_Macro);
|
||||
wxSnprintf(buf, sizeof(buf), _T("Warning: could not find hotspot reference %s"), hotspots[i].szHlpTopic_Macro);
|
||||
OnInform(buf);
|
||||
}
|
||||
wxFprintf(fd, _T("rect %s %d %d %d %d\n"), refFilename, (int)hotspots[i].left, (int)hotspots[i].top,
|
||||
@@ -157,6 +158,6 @@ bool SHGToMap(wxChar *filename, wxChar *defaultFile)
|
||||
fclose(fd);
|
||||
|
||||
delete[] hotspots;
|
||||
return TRUE;
|
||||
return true;
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user