ChartsOrg / ChartsOrg/Charts

How to fill color only below the zero line and set different line color below the zero line

Open
#5,111 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
Swift
Stars
28k
Forks
6k
PR merge metrics
No merged PRs in 30d

Description

Expectation is to set the different color for line just below the zero line and fill color only below the zero line

## What did you do?

I have tried
`dataset.fillFormatter = DefaultFillFormatter { _, _ in
return CGFloat(uiView.leftAxis.axisMaximum)
}`

Tried

## What did you expect to happen?

Expectation is to change line color just below the zero line and only fill the color just below zero line

Expected

## DGCharts Environment

**DGCharts version/Branch/Commit Number:**
**Xcode version:14.2**
**Swift version:5.0**
**Platform(s) running DGCharts:iOS**
**macOS version running Xcode:12.6.3**

## Demo Project

ℹ Please link to or upload a project we can download that reproduces the issue.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.