riched32.dll refresh(?) problem

Open forum for end-user questions about Wine. Before asking questions, check out the Wiki as a first step.
Forum Rules
Locked
jbrown

riched32.dll refresh(?) problem

Post by jbrown »

An application using a riched32 input text box runs almost fine. The box has two indicators, one is "total lines" and the other is the cursor position "line/column".

When entering text, everything seems fine and the "total lines" counter changes whenever I press ENTER, but the "line/column" cursor position remains staying at "1/1". When I copy text into the box, the cursor moves (though indicator still says "1/1"), but I don't see the copied text. After scrolling one page and scrolling back, the text shows up.

It seems that there is some kind of screen update missing.

I tried that with the built-in riched32.dll as well as with several native ones.

Anyone any idea?

(wine is v1.2)
James McKenzie

riched32.dll refresh(?) problem

Post by James McKenzie »

jbrown wrote:
An application using a riched32 input text box runs almost fine. The box has two indicators, one is "total lines" and the other is the cursor position "line/column".
Unless you are running in Windows 95 mode, the proper file is riched20.
When entering text, everything seems fine and the "total lines" counter changes whenever I press ENTER, but the "line/column" cursor position remains staying at "1/1". When I copy text into the box, the cursor moves (though indicator still says "1/1"), but I don't see the copied text. After scrolling one page and scrolling back, the text shows up.

It seems that there is some kind of screen update missing.

I tried that with the built-in riched32.dll as well as with several native ones.

These are just wrappers for riched20. You need to get a copy of
riched20.dll from WindowsXP and place it in the same directory as this
program. Then set riched20 to 'native, builtin' for this library file.
If this fixes the problem, please open a bug report.

James McKenzie
User avatar
DanKegel
Moderator
Moderator
Posts: 1164
Joined: Wed May 14, 2008 11:44 am

Post by DanKegel »

The easy way to get native riched20 is
winetricks riched20

For instance,
wget http://kegel.com/wine/winetricks
sh winetricks riched20

See http://wiki.winehq.org/winetricks
User avatar
trivodata
Newbie
Newbie
Posts: 3
Joined: Thu Aug 12, 2010 5:13 pm

backup

Post by trivodata »

Always drag a backup of this file.. I've had a corresponding problem like this and it knocked out the whole system..
jbrown

Re: riched32.dll refresh(?) problem

Post by jbrown »

James McKenzie wrote:You need to get a copy of riched20.dll from WindowsXP and place it in the same directory as this program. Then set riched20 to 'native, builtin' for this library file.
Thanks, this works.

So far, I copied native dlls into wine's system32 directory. If I do so for riched20, the program doesn't even start (same if I copy XP's riched32 and set it to 'native, builtin' for the program, too). (Maybe because the program was written for riched32.dll?)

What is the trick with the dll in the program's directory? And is it possible to supply all programs with native riched*.dll through system32 directory?
James McKenzie

riched32.dll refresh(?) problem

Post by James McKenzie »

jbrown wrote:
James McKenzie wrote:
You need to get a copy of riched20.dll from WindowsXP and place it in the same directory as this program. Then set riched20 to 'native, builtin' for this library file.
Thanks, this works.

So far, I copied native dlls into wine's system32 directory. If I do so for riched20, the program doesn't even start (same if I copy XP's riched32 and set it to 'native, builtin' for the program, too). (Maybe because the program was written for riched32.dll?)
Is the program a Windows95 program? That is the only version that
should be written to use riched32 calls. However, you can copy the
riched32.dll file from your Windows partition to the program directory.
What is the trick with the dll in the program's directory? And is it possible to supply all programs with native riched*.dll through system32 directory?

This is not recommended as we implement richedit calls differently than
does any version of Windows (there are legal reasons to do this.) You
can set the default to be native, built-in through the libraries tab for
the default installation and then put these files in the program
directories. BTW, Office 2003/2007 do come with their own versions of
richedit and they are installed in the program installation directories
for those programs.

James McKenzie
jbrown

Re: riched32.dll refresh(?) problem

Post by jbrown »

James McKenzie wrote:Is the program a Windows95 program?
I'm not sure, but it is a very old program, so it's likely.
James McKenzie wrote:However, you can copy the riched32.dll file from your Windows partition to the program directory.
Unfortunately, this doesn't work.

If I copy either the riched32.dll provided with the program or my Windows partition's riched32.dll or XP's riched32.dll (with riched20.dll in systems32 then) into the program's directory, I get the refresh problem.

If I copy riched20/32.dll into system32, I get the refresh problem.

If I set a soft link to system32/riched20.dll into the program's directory or copy riched20.dll directly there, it works.

(All, of course, with riched20/32.dll set 'native, builtin'.)

BTW, another reason to have riched20.dll accessible for all programs is wine's wordpad.exe. With the default installation, I get not list bullets. After copying riched20.dll into system32 and setting it 'native, builtin' for wordpad.exe, the bullets appear.

So where to copy the dll to have it 'native, builtin' for a couple of programs (especially if they resist in system32 themselves) and 'builtin' as default for the rest of it?
User avatar
dimesio
Moderator
Moderator
Posts: 13373
Joined: Tue Mar 25, 2008 10:30 pm

Re: riched32.dll refresh(?) problem

Post by dimesio »

jbrown wrote: So where to copy the dll to have it 'native, builtin' for a couple of programs (especially if they resist in system32 themselves) and 'builtin' as default for the rest of it?
If you copy it to one program's directory, other programs will not be able to find it. If you need riched20 for more than one program, it's easiest to put it in system32 (that's where winetricks installs it). Set the overrides individually for each app that needs it rather than globally.
jbrown

Post by jbrown »

I experienced serious problems with the program's 'undo' function with XP's dlls, so I decided to go back to the older riched32.dlls and lack the refresh when copying. :sad:
Locked