Skip to content
Open
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Remove angle attribute
  • Loading branch information
degzhaus committed Nov 29, 2025
commit dec915a1b9f675ba605da8f3dbae4089d95b4a34
8 changes: 0 additions & 8 deletions src/traces/quiver/attributes.js
Original file line number Diff line number Diff line change
Expand Up @@ -65,14 +65,6 @@ var attrs = {
'or *cm*/*center*/*middle* to center the arrow on (x,y).'
].join(' ')
},
angle: {
valType: 'number',
dflt: Math.PI / 9,
min: 0,
max: Math.PI / 2,
editType: 'calc',
description: 'Angle of arrowhead in radians. Default = π/9'
},
hoverdistance: {
valType: 'number',
min: -1,
Expand Down
1 change: 0 additions & 1 deletion src/traces/quiver/defaults.js
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,6 @@ module.exports = function supplyDefaults(traceIn, traceOut, defaultColor, layout
coerce('arrowsize', 1);
// back-compat
coerce('arrow_scale');
coerce('angle', Math.PI / 9);
coerce('hoverdistance', 20);

// Line styling
Expand Down
9 changes: 6 additions & 3 deletions src/traces/quiver/plot.js
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,10 @@ function plotOne(gd, idx, plotinfo, cdscatter, cdscatterAll, element, transition
var arrowScale = (trace.arrowsize !== undefined)
? (baseHeadScale * trace.arrowsize)
: (trace.arrow_scale !== undefined ? trace.arrow_scale : baseHeadScale);
var angle = trace.angle || Math.PI / 12; // small default
// Fixed arrowhead wedge angle (radians).
// Arrow direction is fully determined by u,v (see barbAng below);
// this constant only controls the opening of the head.
var headAngle = Math.PI / 12;

var u = (trace.u && trace.u[cdi.i]) || 0;
var v = (trace.v && trace.v[cdi.i]) || 0;
Expand All @@ -138,8 +141,8 @@ function plotOne(gd, idx, plotinfo, cdscatter, cdscatterAll, element, transition
var arrowLen = barbLen * arrowScale;
var barbAng = Math.atan2(dy, dx / scaleRatio);

var ang1 = barbAng + angle;
var ang2 = barbAng - angle;
var ang1 = barbAng + headAngle;
var ang2 = barbAng - headAngle;

var x0, y0, x1, y1;
if (anchor === 'tip') {
Expand Down