PINE LIBRARY
已更新

Color Library // AlgoFyre

705
AlgoFyre's Color Library is a Pine Script v5 library offering fire-themed palettes with light and dark modes. It helps traders easily integrate consistent, visually appealing color schemes into TradingView indicators. Used in AlgoFyre's Scripts and Indicators.

Color Overview
The AlgoFyreColorLibrary includes a comprehensive set of colors inspired by fire, ranging from light reds and oranges to dark browns and deep reds. The library is divided into two main themes:

Light Theme:
Includes lighter shades of red, orange, and brown, suitable for use on light backgrounds.

Dark Theme:
Includes darker shades of red, orange, and brown, suitable for use on dark backgrounds.

How to Use
To use the AlgoFyreColorLibrary in your Pine Script indicators and strategies, follow these steps:

Import the Library:
Import the AlgoFyreColorLibrary at the beginning of your script.

Call the getColor Function:
Use the getColor function to retrieve the desired color with the specified transparency.

Example
Pine Script®
//@version=5 import "AF-L-0001" as af // Example usage of getColor function color primaryColor = af.getColor("af_primary1", 50) color signalColor = af.getColor("af_green", 80) // Plotting example plot(close, color=primaryColor, linewidth=2, title="Primary Color Line") plot(close, color=signalColor, linewidth=2, title="Signal Color Line")


The library AF-L-0001 is imported with the alias af.
The getColor function is used to get colors with specified transparency.
The colors are then used to plot lines on the chart.
發行說明

  • Changed how colors are requested and what is returned. Now returns a const color object.
發行說明

  • Added RGB versions which can be retreived with colorname_rgb
發行說明

  • Some minor fixes
發行說明

  • Testing RGB return in numbers
發行說明

  • Some minor bugfixes and testing
發行說明
  • Changed the function export to yield simple data types instead of series
發行說明
  • Added more signal colors
  • Signal colors now have a light, normal and dark variant
  • Added copy/paste enum, which can be used as an options enum for color selections in the main script. Just call the getColorByName() function with the name from the enum to get the correct color.
發行說明
  • Some minor cosmetic fixes
  • Added transparency parameter again
發行說明
  • Some minor cosmetic changes
發行說明
  • Changed export function parameters back to series type
  • Added a ENUM to String converter function
發行說明
  • Modified colors
  • Renamed variables and made them const

免責聲明

這些資訊和出版物並不意味著也不構成TradingView提供或認可的金融、投資、交易或其他類型的意見或建議。請在使用條款閱讀更多資訊。