How to scroll text ?
-
Hi I want a MFC application in which I want to scroll some text. Also sometime text might be long and sometimes it might be short. Also Font size of text might need to be as big as 200. So is there a way to do it ? I tried using CBannerStatic example given in this site, but problem occurs when i make my text size big. It stops scrolling and consumes 100% CPU making other application work very very slow. So I want to make it myself and text shold scroll smothly without any flickering.....is there a way to do this ? Thankx a lot in advance Amarelia Maehsh Gujarat India
-
Hi I want a MFC application in which I want to scroll some text. Also sometime text might be long and sometimes it might be short. Also Font size of text might need to be as big as 200. So is there a way to do it ? I tried using CBannerStatic example given in this site, but problem occurs when i make my text size big. It stops scrolling and consumes 100% CPU making other application work very very slow. So I want to make it myself and text shold scroll smothly without any flickering.....is there a way to do this ? Thankx a lot in advance Amarelia Maehsh Gujarat India
-
Hi I want a MFC application in which I want to scroll some text. Also sometime text might be long and sometimes it might be short. Also Font size of text might need to be as big as 200. So is there a way to do it ? I tried using CBannerStatic example given in this site, but problem occurs when i make my text size big. It stops scrolling and consumes 100% CPU making other application work very very slow. So I want to make it myself and text shold scroll smothly without any flickering.....is there a way to do this ? Thankx a lot in advance Amarelia Maehsh Gujarat India
I have used this one AIM-Style Scrolling Banner Control [^]and found it to work fairly well. Either way, why note dissect the code locate the problem and let the author know. Most authors seem to enjoy others helping them with their projects.
DEBUGGING : Removing the needles from the haystack.
-
Hi I want a MFC application in which I want to scroll some text. Also sometime text might be long and sometimes it might be short. Also Font size of text might need to be as big as 200. So is there a way to do it ? I tried using CBannerStatic example given in this site, but problem occurs when i make my text size big. It stops scrolling and consumes 100% CPU making other application work very very slow. So I want to make it myself and text shold scroll smothly without any flickering.....is there a way to do this ? Thankx a lot in advance Amarelia Maehsh Gujarat India
:laugh:if dit a bit research and kame up hith this progy its basicly a simple scrol text not supper fine but it choud wordk if you make it further trik is in this
void CScrolDlg::OnBUTTONstartStop() { // TODO: Add your control notification handler code here m_Scroltextje = m_InputTextVariabel; m_scrollengt = m_Scroltextje.GetLength(); m_scrollengt = m_scrollengt -1 ; //er 1 van af halen // m_Scroltextje.Delete(m_scrollengt,1);// this is for if the scrol text choud end m_Scroltextje.Delete(0,m_scrollengt+1);// this is for if the begin of the scrol text // 0=this is the position in text // scrolltext+1 = amoud of charackters wat must be deleted UpdateData(FALSE); }
but you have to do make it a litle completer i cant do al the work 4 u but basicly it works simple like this her is the link for hole litle project i make http://www.palcopy.com/down_load/scrol.zip[^] you have to do the scrol in a timer function thats all i think you can figure it out this way greetings to al of you -- modified at 8:11 Thursday 10th November, 2005 -
Hi I want a MFC application in which I want to scroll some text. Also sometime text might be long and sometimes it might be short. Also Font size of text might need to be as big as 200. So is there a way to do it ? I tried using CBannerStatic example given in this site, but problem occurs when i make my text size big. It stops scrolling and consumes 100% CPU making other application work very very slow. So I want to make it myself and text shold scroll smothly without any flickering.....is there a way to do this ? Thankx a lot in advance Amarelia Maehsh Gujarat India
Amarelia wrote:
So is there a way to do it ?
Of course there is, but it can become complicated. Only print the part of the text that needs to be seen and nothing else. That is you need to know: which is the first visible character and what its x coordinate is, as well as which visible character is last. Check out GetTextExtent() amongst others. Oh, one last note: The Windows text output functions states that they are limited to 8192 characters. That's not exactly true, the number of characters depend on the size of the font; in otherwords, the total number of pixels in the string length is limited to 32767. INTP Every thing is relative...