multiline strings in .rc files (was: Implementation of "start.exe", take 3)
davep at cyw.uklinux.net
Sat Jan 18 15:11:10 CST 2003
On Saturday 18 Jan 2003 19:29, Dan Kegel wrote:
> davep wrote:
> > On Saturday 18 Jan 2003 08:44, Dan Kegel wrote:
> >>Remaining issue I could use help with:
> >>* multiline strings from resource file are displayed with extra newline
> >>between lines in wine, but not in windows. To reproduce, build
> >>either as winelib app or build under MSVC6, then run in wine;
> >>usage message comes out double-spaced. Help!
> > Use a backslash on the end of each line to escape the LF.
> > Look at programs/wcmd/wcmdrc.rc for an example.
> I did. Unfortunately, if I do
> STRING_FOO, "This is a two-line \
> it looks good in Wine, but it's run together on one line in Windows.
> Conversely, if I do
> STRING_FOO, "This is a two-line \n \
> it looks good in Windows, but it's double-spaced in Wine.
> Something's fishy here. Our .rc files should be
> usable in both environments without change.
I suspect it's a resource compiler thing. The history predates the
mailing-list archives at winehq and also my own mail archive so it must be
before 1999, but IIRC at that time the only resource compiler to support
multi-line text was Borland's. At the time I was tinkering with WineLib
applications and also working on wcmd, so I suggested to the developer of
Wine's resource compiler that he follow the Borland convention. It seems
that MS compilers now accept a similar but incompatible syntax (how unusual)
which is the cause of your confusion.
More information about the wine-devel