GRAPH SetPenSize Problem

    This site uses cookies. By continuing to browse this site, you are agreeing to our Cookie Policy.

    • 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);

      The post was edited 6 times, last by mahdi ().

    • 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
      Please read the forum rules before posting.

      Keep in mind, this is *not* a support forum.
      Our engineers will try to answer your questions between their projects if possible but this can be delayed by longer periods of time.
      Should you be entitled to support you can contact us via our support system: segger.com/ticket/

      Or you can contact us via e-mail.