Comments (11)
Why not disable drawing when drawing is selected?
stockChart.events.on('drawingselected', function (ev) {
unSelectTool();
})
stockChart.events.on('drawingunselected', function (ev) {
activeDrawSelection(true);
})
from amcharts5.
Why not disable drawing when drawing is selected?
True!
That's why I have added it as an alternative!
from amcharts5.
@shishima123 You can do an alternative too,
Once you completed the drawing, change the drawing tool to the anchor tool.
By this a new drawing won't appear.
from amcharts5.
Thanks @workingbuddy10
Can you give me example code?
Or please edit my jsfiddle
from amcharts5.
@shishima123 For testing purpose remove all method on drawingadded
event and then Just add this line
stockChart.events.on('drawingadded', () => {
drawingControl.set("tool", "anchor");
})
from amcharts5.
Thank you for your reply @workingbuddy10
I have added your code, but it doesn't seem to solve the issue I'm facing.
After a drawing is selected, when clicking outside (focus out), a new drawing is still being created before the "drawingunselected" event is actually executed.
simplescreenrecorder-2024-08-30_17.58.45.mp4
from amcharts5.
If you disable drawing when a drawing is selected, you won't be able to use features like changing color, font, line style, etc.
I want these features to still function normally when a drawing is selected
from amcharts5.
Unfortunately, there's no way to disable drawing without exiting drawing mode 🙁
stockChart.events.on("drawingadded", function () {
drawingControl.set("active", false);
});
from amcharts5.
When you set drawingControl to false, the toolbar will also disappear, which is not entirely correct.
I think the drawingunselected event should be executed before the startingdrawing event or something similar
from amcharts5.
Related Issues (20)
- Can we sync the multiple stockchart HOT 1
- Chart stock with large data HOT 5
- ValueAxis tooltip position HOT 1
- Unable to close indicators stockchart HOT 3
- Question: V5 JSON Config to hide PieChart slices label and use circles as legend marker HOT 13
- Responsive chart issue HOT 1
- Erase the rounded ends of the shapes after drawing. HOT 2
- Clustered columns chart Is very slow with large data HOT 1
- Unable to create Axis range in stockchart HOT 10
- XY Chart with categories not showing all categories after upgrade from 5.9.13 to 5.10.x HOT 1
- Replicating a chord diagram HOT 2
- Rangechanged event not firing as expected HOT 3
- In Bar chart how to align Labels to Bar when few labels are shown on axis? HOT 1
- Possible to sync Orderflow chart with the stockChart HOT 3
- Add LICENCE file to the root of the folder for easier to find. HOT 1
- Bug Drawing Label don't appear letters HOT 1
- Prevent focus in Label Tool Drawings HOT 1
- How I can get the DateAxis label as HTML? HOT 5
- Heatmap config
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from amcharts5.