Telerik Forums
Kendo UI for jQuery Forum
1 answer
25 views

Hello Telerik

First check this example : https://dojo.telerik.com/oraZInUQ

Q1. When constructing a diagram like this, if the length of the textblock text becomes larger than the length of the rectangle, is there a way to control this? I wish there was a line break.

Q2. The length of the text is longer, so the selection area for the shape has increased. I want the selection area to be based on the width and height of the rectangle. Is it possible to adjust the selection area of ​​shape?

Thank you for your reply.

Nikolay
Telerik team
 answered on 14 Dec 2023
1 answer
61 views

Hello,

 

I'm creating a diagram. I've done some research on how to create a custom shape, but I'm having a few problems on dynamically modifying the data of the various elements present in the shape.

1) Firstly, I've understood the code bellow that allows me to create a custom shape:

 

let newShape = function() {
            let dataviz = kendo.dataviz
            let g = new dataviz.diagram.Group()
            let dataItem = options.dataItem

            g.append(new dataviz.diagram.Rectangle({
                width: 210,
                height: 75,
                stroke: {
                    width: 0
                },
                fill: {
                    gradient: {
                        type: 'linear',
                        stops: [{
                            color: dataItem.colorScheme,
                            offset: 0,
                            opacity: 0.5
                        }, {
                            color: dataItem.colorScheme,
                            offset: 1,
                            opacity: 1
                        }]
                    }
                }
            }))
            
            g.append(new dataviz.diagram.TextBlock({
                text: dataItem.name,
                x: 20,
                y: 20,
                fill: '#fff'
            }))
            
            g.append(new dataviz.diagram.TextBlock({
                text: dataItem.props,
                x: 20,
                y: 40,
                fill: '#fff'
            }))
            return g
}

However,  I'm having trouble dynamically modifying the value of a TextBlock. 

 

Which field do I need to access, after retrieving the shape via diagram.shapes[i] , to be able to modify the "text" field of a TextBlock? Or, more generally, how can I easily retrieve an element (TextBlock, etc.) from a compound shape?

 

I've tried accessing various fields in the shape object referring to the TextBlock element and then calling shape[i].redraw( ) / .redrawVIsual( ), but no shape is updated.

 

2) Secondly, what kind of components can be added to the Group ? My goal is to add a progress bar into my shape, but I don't think that's possible. Is there a list of elements (TextBlocks, ...) that can be appended to Group ? Or any idea to have a progress bar in a shape ? Maybe using the progressbar component and attach a progress bar to each shape ? 

 

Thanks in advance, 

 

Best,

VB

Neli
Telerik team
 answered on 10 Aug 2023
1 answer
72 views

I need to add a button inside a diagram element as example inside a shape or group elements, if it is not possible, add a pop up menu or something similar... 

Do you have any advice?

Nikolay
Telerik team
 answered on 17 Jul 2023
4 answers
292 views
We are trying to build organizational chart using Kendo UI for jQuery component DIAGRAM. Does this component provide Expand/Collapse functionality like your Telerik UI for ASP.NET AJAX component ORG CHART does?
If it doesn’t, what is the best way to implement expand/collapse functionality? May be there are some jQuery plugins built for this purpose or Kendo UI for jQuery has other component which fits better for building organizational chart. Any advice appreciated.
Sami
Top achievements
Rank 2
Iron
Iron
Iron
 answered on 08 Jul 2023
1 answer
131 views

My requirement is to create a diagram which is using different widgets to child and parent nodes. Is there a way to use two or more different custom templates for parent and its child nodes. Please see the image below that is something I want to create

 

 

 

Georgi Denchev
Telerik team
 answered on 28 Mar 2023
1 answer
62 views

Hello,

We have a diagram with layered layout, aligned to right. The diagram can have one or more root nodes.

The problem is that when we have multiple roots, we want to align them one under another, instead, if they are not very long, they are aligned to the right of each other.

Is there a way to achieve this alignment? We searched documentation but didn't find any specific property.

I attach images of how the diagram looks now and how we need it to look.

 

Thanks,

Iuliana

Nikolay
Telerik team
 answered on 27 Oct 2022
1 answer
60 views

In our project we have a web page that produces a diagram on screen; we would like to take this diagram and place it in a report. The report is generated on our server and the diagram is obviously shown in the browser on the client computer.

My question is, is there a way of taking the current view and sending it to the server and may be storing it in the database as a BLOB image? If I can do this then I will be able to insert the image in to the reports I generate/build.

Georgi Denchev
Telerik team
 answered on 23 Mar 2022
1 answer
88 views
We are not able to generate pdf in phone 11 safari browser. we are using kendo pdf export (save As method). we are not getting any error in console.
Martin
Telerik team
 answered on 28 Feb 2022
2 answers
227 views

Hello,

 

I am working with diagrams and I need to replace connection textbox for a link.

I tryed setting content, template and visual, but nothing worked.

That does not work, the id I set to the group doest not appear in the HTML :/

Is there anyway to do it?

 

Thanks!

MaiK
Top achievements
Rank 1
Iron
 answered on 23 Nov 2021
Narrow your results
Selected tags
Tags
+? more
Top users last month
Mark
Top achievements
Rank 1
Yurii
Top achievements
Rank 1
Leland
Top achievements
Rank 2
Iron
Iron
Iron
Hon
Top achievements
Rank 1
Iron
Deltaohm
Top achievements
Rank 3
Bronze
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Mark
Top achievements
Rank 1
Yurii
Top achievements
Rank 1
Leland
Top achievements
Rank 2
Iron
Iron
Iron
Hon
Top achievements
Rank 1
Iron
Deltaohm
Top achievements
Rank 3
Bronze
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?