Home > Software engineering >  MFC CListCtrl how to realize the horizontal scroll?
MFC CListCtrl how to realize the horizontal scroll?

Time:10-06

Now the situation is: vertical scrolling
List and a growing number of the top column shows the recent update of the specific content of the project. (thread control keep adding)
So the list is constantly scroll down.
I want to set this list for horizontal scrolling.
To search on the net of all is a horizontal scroll bar information. The elder sister ask you people give an opinion.
Images:


Initialization code:
 
DWORD dwExStyle=LVS_EX_FULLROWSELECT | LVS_EX_GRIDLINES | LVS_EX_HEADERDRAGDROP | LVS_EX_ONECLICKACTIVATE;

Cstrings resloader;

VideoControl. ModifyStyle (0, LVS_SINGLESEL | LVS_REPORT | LVS_SHOWSELALWAYS);
VideoControl. SetExtendedStyle (dwExStyle);
//resloader LoadString (IDS_VIDEODECODE_NUM);
//VideoControl. InsertColumn (0, resloader LVCFMT_CENTER, 50, 0).

Resloader. LoadString (IDS_VIDEODECODE_PTS);
VideoControl. InsertColumn (0, resloader LVCFMT_CENTER, 55, 0).

Resloader. LoadString (IDS_ELECMASHION1);
VideoControl. InsertColumn (1, resloader LVCFMT_CENTER, 50, 0).
Resloader. LoadString (IDS_ELECMASHION1FLAG1);
VideoControl. InsertColumn (2, resloader, LVCFMT_CENTER, 20, 0).
Resloader. LoadString (IDS_ELECMASHION1FLAG2);
VideoControl. InsertColumn (3, resloader, LVCFMT_CENTER, 20, 0).
Resloader. LoadString (IDS_ELECMASHION1FLAG3);
VideoControl. InsertColumn (4, resloader, LVCFMT_CENTER, 20, 0).

Resloader. LoadString (IDS_ELECMASHION2);
VideoControl. InsertColumn (5, resloader LVCFMT_CENTER, 50, 0).
Resloader. LoadString (IDS_ELECMASHION2FLAG1);
VideoControl. InsertColumn (6, resloader, LVCFMT_CENTER, 20, 0).
Resloader. LoadString (IDS_ELECMASHION2FLAG2);
VideoControl. InsertColumn (7, resloader LVCFMT_CENTER, 20, 0).
Resloader. LoadString (IDS_ELECMASHION2FLAG3);
VideoControl. InsertColumn (8, resloader, LVCFMT_CENTER, 20, 0).

Resloader. LoadString (IDS_ELECMASHION3);
VideoControl. InsertColumn (9, resloader LVCFMT_CENTER, 50, 0).
Resloader. LoadString (IDS_ELECMASHION3FLAG1);
VideoControl. InsertColumn (10, resloader LVCFMT_CENTER, 20, 0).
Resloader. LoadString (IDS_ELECMASHION3FLAG2);
VideoControl. InsertColumn (11, resloader, LVCFMT_CENTER, 20, 0).
Resloader. LoadString (IDS_ELECMASHION3FLAG3);
VideoControl. InsertColumn (12, resloader LVCFMT_CENTER, 20, 0).

CodePudding user response:

Beg a little advice. Other similar class or other things is ok, as long as it can realize the horizontal scrolling, beg a little. I can feel our. Thank you

CodePudding user response:

More than natural rolling column width

CodePudding user response:

refer to the second floor gz_qmc response:
column width more than natural scrolling

Hello, I want is horizontal scroll (scroll from left to right), rather than the vertical scrolling, have any good Suggestions?

CodePudding user response:

The painting is king
You can roll sideways like

Programming world the most sad is not data structure
  • Related