| |

VerySource

 Forgot password?
 Register
Search
View: 1305|Reply: 10

Is there a more "sane" way to redraw the borders of a ListView?

[Copy link]

1

Threads

5

Posts

6.00

Credits

Newbie

Rank: 1

Credits
6.00

 China

Post time: 2020-3-13 08:30:01
| Show all posts |Read mode
I want to redraw the border of the ListView, but I found that the border can't be cleared by using the Clear (Color) method after getting the ListView's Graphics interface, let alone redrawing ~~ Setting the ListView's BorderStyle to BorderStyle.None can remove the edges, but ListView has fewer pixels, and it can't be drawn ~~~

Someone introduced that I can set the BorderStyle to None, and then put a Panel under the ListView and draw the edges on the Panel. Although this is feasible, is there any other way to directly redraw the edges of the ListView?

Looking forward to your help!
Reply

Use magic Report

0

Threads

5

Posts

6.00

Credits

Newbie

Rank: 1

Credits
6.00

 China

Post time: 2020-6-23 22:45:01
| Show all posts
What does it mean to have fewer pixels?

Do you use detail display or big icons?
Reply

Use magic Report

0

Threads

5

Posts

6.00

Credits

Newbie

Rank: 1

Credits
6.00

 China

Post time: 2020-6-24 01:30:01
| Show all posts
I don’t know what’s wrong with setting to none
Reply

Use magic Report

1

Threads

5

Posts

6.00

Credits

Newbie

Rank: 1

Credits
6.00

 China

 Author| Post time: 2020-6-24 23:45:01
| Show all posts
That is to say, if there is an edge, the edge occupies one pixel, and now there is no edge, there is one pixel on each side
Reply

Use magic Report

0

Threads

14

Posts

12.00

Credits

Newbie

Rank: 1

Credits
12.00

 United States

Post time: 2020-6-25 23:15:01
| Show all posts
That is to say, if there is an edge, the edge occupies one pixel, and now there is no edge, there is one pixel on each side

Do not understand what effect this has?
Reply

Use magic Report

1

Threads

5

Posts

6.00

Credits

Newbie

Rank: 1

Credits
6.00

 China

 Author| Post time: 2020-6-26 20:45:01
| Show all posts
The effect is: I want to redraw the side of the ListView, one pixel is missing, and the side I want to draw is drawn inside~
If ListView is in detail or list state, it will affect the items and columns in it~

But now I can’t draw anyway...T_T
Reply

Use magic Report

0

Threads

5

Posts

6.00

Credits

Newbie

Rank: 1

Credits
6.00

 China

Post time: 2020-7-14 13:00:01
| Show all posts
Do you want to say that if it is useful, it will be an extra line,

With none, there is one less line, but the white part will stretch out?
Reply

Use magic Report

1

Threads

5

Posts

6.00

Credits

Newbie

Rank: 1

Credits
6.00

 China

 Author| Post time: 2020-7-23 16:00:01
| Show all posts
Yes, if you use ordinary ones, there will be one more line, and if you use none, there will be one less line. But my goal now is to have this line, and I want to draw this line by myself. If it's normal, the line appears, and I can't cover it no matter how I redraw it.
Reply

Use magic Report

0

Threads

5

Posts

6.00

Credits

Newbie

Rank: 1

Credits
6.00

 China

Post time: 2020-7-27 06:30:02
| Show all posts
Car~~~ You can add multiple panels to calculate and live in an anchor meter. Anyway, .net will have to expose a lot of memory windows

You add multiple panel bases and all 5 are competing
Reply

Use magic Report

1

Threads

5

Posts

6.00

Credits

Newbie

Rank: 1

Credits
6.00

 China

 Author| Post time: 2020-7-27 15:00:01
| Show all posts
.... I have considered the situation you mentioned. The original post on the first floor also wrote it, but it is currently not allowed to be implemented in this situation.
Reply

Use magic Report

You have to log in before you can reply Login | Register

Points Rules

Contact us|Archive|Mobile|CopyRight © 2008-2023|verysource.com ( 京ICP备17048824号-1 )

Quick Reply To Top Return to the list