Questions tagged [custom-draw]

67 questions
33
votes
8 answers

TreeNode Selected BackColor while TreeView not focused

Is there an easy way to have a selected TreeNode retain its SystemColors.Highlight BackColor while the TreeView doesn't have focus? Because even with HideSelection set to false, the selected BackColor is near impossible to see. Selected TreeNode…
Spark
  • 1,007
  • 1
  • 8
  • 26
13
votes
2 answers

How to clip a circular path inside a rectangle in Android

I've read over 20 questions/answers but I still can't get what I want. I want to cut a circle inside a rectangle as seen below: Here is my code: @Override protected void onDraw(Canvas canvas) { Paint paint = new Paint(); …
11
votes
5 answers

Win32: How to custom draw an Edit control?

i need to implement the functionality of EM_SETCUEBANNER, where a text hint appears inside an Edit control: The catch is that i cannot use version 6 of the Common Controls, which is what is required to get the Microsoft supplied implementation of a…
Ian Boyd
  • 246,734
  • 253
  • 869
  • 1,219
8
votes
1 answer

Display extra text in treeview nodes, not just node.text

I have a TTreeView in Delphi, with nodes at three levels. I use node data to store another label besides the node text. Type TNodeData = class ExtraNodeLabel: WideString; //... other members end; I have an OnAdvancedCustomDrawItem…
beerwin
  • 9,813
  • 6
  • 42
  • 57
7
votes
5 answers

Win32 List-View Control SubItem padding for custom-drawn SubItems?

When using custom-draw (NM_CUSTOMDRAW) to draw the entire contents of a ListView SubItem (in Report/Details view), it would be nice to be able to apply the same left and right padding in my custom paint method that is applied by the control itself…
David Citron
  • 43,219
  • 21
  • 62
  • 72
7
votes
2 answers

Is there a way to draw a filled area with Canvas without using Path?

I am wondering if there is a way to draw filled areas (like a filled polygon) with the Android Canvas without using the Path class and call canvas.drawPath(...). The reason I want to do this without Path is because I have to draw very large datasets…
Philipp Jahoda
  • 50,880
  • 24
  • 180
  • 187
7
votes
2 answers

Add graphical bar to a StringGrid col

Using Delphi 2010 and a TStringGrid component, I currently display five filds from a database query. Here is a simplied example of what i am doing //set up the grid procedure TGriddata.FormCreate(Sender: TObject); begin …
Blow ThemUp
  • 895
  • 6
  • 18
  • 29
5
votes
0 answers

How to convince CListCtrl to view selection for each column (subitem)

I have my own CListCtrl (MyList : public CListCtrl) and I want to show selection for each column, not for entire row. I changed WM_LBUTTONDOWN message and WM_KEYDOWNMESSAGE and set current column to m_iCurCol. And then I have …
Michal Hadraba
  • 347
  • 1
  • 11
5
votes
1 answer

Treeview node with transparent text background instead of default white

I am using custom draw to try and create transparent tree view ( for now I am testing when Visual Styles are enabled ). My CDDS_PREPAINT handler works fine, tree has parent's background bitmap drawn properly. I tried to add CDDS_ITEMPREPAINT…
AlwaysLearningNewStuff
  • 2,939
  • 3
  • 31
  • 84
4
votes
1 answer

Show Selected Image in DataGridView with DataGridViewComboBoxColumn?

I have a problem in using DataGridView with DataGridViewComboBoxColumn to let user to select an image from a list of images. Following the discussions in the Question titled "Custom draw of DatagridViewComboBoxColumn" ref Link. I also face the…
4
votes
5 answers

Draw over controls in Delphi form

How can I draw something on the Forms canvas and over controls on the Form? I try the following: procedure TForm1.FormPaint(Sender: TObject); var x,y: Integer; begin x := Mouse.CursorPos.X - 10; y := Mouse.CursorPos.Y - 10; x :=…
iamjoosy
  • 3,299
  • 20
  • 30
4
votes
1 answer

Implementing a TLabel with TabStop and FocusRect?

I'm using Delphi7 and I'm trying to implement a LinkLabel like the ones you can find under the Control Panel on Windows Vista and above. Changing the cursor/color on hover is really simple, the only thing I need to do is to make the TLabel receive…
Steve
  • 2,510
  • 4
  • 34
  • 53
4
votes
3 answers

Custom drawing of a QSlider (Qt)

I want to intercept the QPaintEvent on a QSlider and draw it. But I can not find the details on the geometry of the thing. I can know the rect() of the whole widget but how can you tell the position of first tickmark or the last one in the widget's…
tru7
  • 6,348
  • 5
  • 35
  • 59
4
votes
0 answers

infinite scrolling with custom view in Android

I'am programming a calendar application which shows the appointments in a week-oriented view. I implemented the graphics by custom drawing in onDraw() of a View. The graphics contains fixed parts (time bar) and calendar relative parts (days,…
3
votes
2 answers

Indent tab in TabControl

I'd better illustrate what I want to achieve. Original:                         Desired:                 Any ideas how to draw tabs in this way? Thanks.
Dmitrii Erokhin
  • 1,347
  • 13
  • 31
1
2 3 4 5