Hacktoberfest 2026:维护者为十月标记出来的 issue,仍然开放、适合新手。 浏览 Hacktoberfest issue

Allow custom colors in folium.Icon

未关闭 适合新手
#2,293 1 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看

维护者通常 1 天内回复

还没有人认领这个 Issue。

评估

难度
2/5
预计耗时
1-3 小时
新手友好度
72/100
Issue 类型
功能
描述清晰度
基本清楚
活跃度
活跃
技术栈
python

调研方向

从 folium.Icon 的实现入手,检查颜色参数目前是如何被限制为预定义值的。添加对自定义 HTML/HEX 颜色的支持,同时保留现有标记的形状、大小、图标和外观,然后检查或添加对 issue 中示例颜色的覆盖。

由索引模型根据 Issue 内容生成。

描述

Hi,
I would like to suggest expanding the color options available in folium.Icon.

Currently, the color parameter accepts a predefined list of colors, for example:

folium.Icon(color="darkgreen", icon="glyphicon-map-marker")

It would be very useful if color could also accept custom HTML/HEX colors, for example:

folium.Icon(color="#00A6A6", icon="glyphicon-map-marker")

The goal would simply be to allow users to choose more colors while keeping exactly the same marker shape, size, icon, and appearance provided by folium.Icon.

For example, being able to use colors such as:

#00A6A6
#FF6600

would provide much more flexibility when categorizing markers on a map.

I think this could be a useful

Thank you for maintaining Folium and for considering this suggestion!

主要语言
Python
星标
7.4k
派生
2.3k
平均合并
3 小时 25 分钟
30 天内合并 PR
9

环境准备

  • 没有 Dockerfile 或 Docker Compose 文件
  • 没有 Pull Request 模板
  • 阅读贡献指南

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

python-visualization/folium 的其他 Issue

查看 python-visualization/folium 的全部 Issue

相似的 Issue

更多 Python Issue

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。