question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

row chart title label needs dy offset

See original GitHub issue

rowChart with renderTitleLabel(true) has vertically misaligned title labels: rowchart

Both labels and titles have the same y, but labels have also dy. Adding dy to titles fixes the problem.

diff --git a/src/row-chart.js b/src/row-chart.js
index d7a16de..347ae7a 100644
--- a/src/row-chart.js
+++ b/src/row-chart.js
@@ -241,6 +241,7 @@ dc.rowChart = function (parent, chartGroup) {
             var titlelab = rows.select('.' + _titleRowCssClass)
                     .attr('x', _chart.effectiveWidth() - _titleLabelOffsetX)
                     .attr('y', _labelOffsetY)
+                    .attr('dy', _dyOffset)
                     .attr('text-anchor', 'end')
                     .on('click', onClick)
                     .attr('class', function (d, i) {

Issue Analytics

  • State:closed
  • Created 8 years ago
  • Comments:5 (5 by maintainers)

github_iconTop GitHub Comments

1reaction
gordonwoodhullcommented, May 2, 2016

Fixed in 2.0 beta 28. Thanks @adrm!

0reactions
gordonwoodhullcommented, Apr 12, 2016

Yes, please do. There is a lot to keep track of in this project, and all pull requests help, even small ones. Thanks!

Read more comments on GitHub >

github_iconTop Results From Across the Web

OFFSET function to change Source Data for a Dynamic Chart
Since our Defined name is controlled by a Drop List, Changing our selection from the Drop List automatically changes our Chart.
Read more >
Excel Charts: Dynamic Label positioning of line series - XelPlus
Right mouse click on the data label displayed on the chart. Select Format Data Labels. Under the Label Options, show the Series Name...
Read more >
Move and Align Chart Titles, Labels, Legends with ...
The chart titles, labels, and legends can be moved using the arrow ... of points that will offset the chart element from the...
Read more >
Dynamically Label Excel Chart Series Lines
One option is to add the series name labels to the very last point in each line and then set the label position...
Read more >
Creating Dynamic Charts Using the OFFSET Function and ...
Next, we need to repeat the above process, this time using Label for the Name and the formula below in the Refers to...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found