الفريق العربي للبرمجةأرشيف المنتديات · 2000 – 2023
نسخة أرشيفية للقراءة فقط — التسجيل والمشاركة مغلقان، والمحتوى محفوظ كما كان.

One of theTwo

مغلق
بدأه justnow في 12 مايو 2003 · 1 رد · 647 مشاهدة · في الأسئلة المجابة
مشاركة: واتساب X فيسبوك تيليجرام
#1 صاحب الموضوع

There is not third

One of the Two

1You do not want to reply

2You did not understand my question

if the first, I have no thing to do.

If the second,AS I HOPE, I will repeate using an other way

When Writing a programme Using Visual C++

Alwayes you go to put your drawing coad in some function

called

void OnDraw(CDC* pDC)

This function is called whenever the programme

needs to be redrawn or it is the first time to draw it.

Some times Long Code written in this function

or due to a long loop draws, Screen shackes.

for my example

void CConnectTheDotsView::OnDraw(CDC* pDC)
{
	CConnectTheDotsDoc* pDoc = GetDocument();
	ASSERT_VALID(pDoc);
	// TODO: add draw code for native data here


	//Draw the dots
	for(int i=0;im_oaPoints.GetSize();i++)
	{
		//Get the Point
		CMyPoint* ptFromPoint = (CMyPoint*)pDoc->m_oaPoints;
		for(int j=0;jm_oaPoints.GetSize();j++)
		{
			CMyPoint* ptToPoint = (CMyPoint*)pDoc->m_oaPoints[j];
			pDC->MoveTo(ptFromPoint->m_dX,ptFromPoint->m_dY);
			pDC->LineTo(ptToPoint->m_dX,ptToPoint->m_dY);
		}
	}


}

My Question

How can I prevent That to Happen

When I was programming using Java

there was a solution called Double Buffering

which depends on creating an other Image Object and Give

Drawing Function A Handle to this Image , This may Cause the Drawing

Drawnd in the Image while the user seeing a static screen.

then draw this Image on the sceen. I remember It was a potent solution

Please would you tell me What Visual C++ Do

#2

2 :) الرجاء توضيح السؤال أكثر لنعرف ما هو المطلوب بالضبط وارجوا الكتابة باللغة العربية قدر المستطاع

هذا الموضوع مغلق.

مواضيع مشابهة