Wednesday, May 23rd 2018, 5:37am UTC+2

You are not logged in.

  • Login
  • Register

Dear visitor, welcome to SEGGER Forum. If this is your first visit here, please read the Help. It explains how this page works. You must be registered before you can use all the page's features. Please use the registration form, to register here or read more information about the registration process. If you are already registered, please login here.

mahdi

Beginner

Date of registration: Jan 28th 2018

Posts: 8

1

Monday, January 29th 2018, 2:29pm

GRAPH SetPenSize Problem

hello

I created a GRAPH with GUIBuilder and use it.
GRAPH work fine and show attach Data.
but when i use GRAPH_DATA_XY_SetPenSize() to change pen size the size off pen not change.


WM_HWIN MainTask(void) {
WM_HWIN hWin;
WM_HWIN hItem;
GRAPH_DATA_Handle hData1;

hWin = GUI_CreateDialogBox(_aDialogCreate, GUI_COUNTOF(_aDialogCreate), _cbDialog, WM_HBKWIN, 0, 0);

hGraph = WM_GetDialogItem(hWin, ID_GRAPH_0);

hData1 = GRAPH_DATA_YT_Create(GUI_BLUE, 500, 0, 0);
GRAPH_DATA_YT_SetAlign(hData1, GRAPH_ALIGN_LEFT);
GRAPH_DATA_XY_SetLineStyle( hData1, GUI_LS_SOLID);
GRAPH_DATA_XY_SetPenSize(hData1, 5);
GRAPH_AttachData(hGraph, hData1);

This post has been edited 6 times, last edit by "mahdi" (Jan 29th 2018, 2:38pm)


SEGGER - Schoenen

Super Moderator

Date of registration: Aug 13th 2015

Posts: 584

2

Monday, February 5th 2018, 2:01pm

Hi,

The function GRAPH_XY_SetPenSize() is only for setting the pensize of a XY-graph. You have created a YT-graph and can't use the XY related functions.
Unfortunately, there is no way to adapt the pensize for a YT-graph.

In this case you could try to set a user draw function with GRAPH_SetUserDraw() or create your own graph with function the GUI_DrawGraph().

Regards
Sven

mahdi

Beginner

Date of registration: Jan 28th 2018

Posts: 8

3

Monday, February 5th 2018, 9:45pm

I did not pay attention to this 8o

Thanks

riteshSTPL

Beginner

Date of registration: Apr 12th 2017

Posts: 1

4

Thursday, April 5th 2018, 8:52am

Hello,
How can I increase PenSize of YT graph using GRAPH_SetUserDraw()?

Similar threads