Overview
Examples
Screenshots
Comparisons
Applications
Download
Documentation
Tutorials
Bazaar
Status & Roadmap
FAQ
Authors & License
Forums
Funding Ultimate++
Search on this site
Search in forums












SourceForge.net Logo
Home » U++ Library support » RichText,QTF,RTF... » RichText over an image background - weird scroll (on windows)
RichText over an image background - weird scroll (on windows) [message #50657] Thu, 29 November 2018 19:26 Go to next message
mdelfede is currently offline  mdelfede
Messages: 1259
Registered: September 2007
Senior Contributor
Hi,

I've a popup with a background image (painted in Paint() routine) with over a couple of RichTextCtrl with no background, so
I can see the popup background image.
Allo ok, up to I scroll the RichText content; on Linux (GTK) is all ok, on windows the background image gets scrolled
weirdly too, as in the attached gif.
Is there a workaround ?

index.php?t=getfile&id=5708&private=0

Edit : I noticed that if I select the text with mouse, the background gets repainted correctly.

[Updated on: Thu, 29 November 2018 19:32]

Report message to a moderator

Re: RichText over an image background - weird scroll (on windows) [message #50817 is a reply to message #50657] Thu, 03 January 2019 10:04 Go to previous message
mirek is currently offline  mirek
Messages: 11706
Registered: November 2005
Ultimate Member
Try this:

void Scroller::Scroll(Ctrl& p, const Rect& rc, Point newpos, Size cellsize)
{
	if(!IsNull(psb) && !p.IsTransparent()) {
		Point d = psb - newpos;
		p.ScrollView(rc, d.x * cellsize.cx, d.y * cellsize.cy);
	}
	else
		p.Refresh();
	psb = newpos;
}



If it does not help, I will need a testcase...

That said, I think I will remove/depreacete all scrolling support soon (GPUs are fast enough)

Mirek
Previous Topic: Constant font size in resizeable RichEdit?
Next Topic: How to add/enable spell-CORRECTING with richedit (not-quite-solved-sort-of)
Goto Forum:
  


Current Time: Wed Feb 20 11:08:12 CET 2019

Total time taken to generate the page: 0.00612 seconds