# Pen style not work for MAP\_GRID\_PEN

**URL:** <https://forum.generic-mapping-tools.org/t/pen-style-not-work-for-map-grid-pen/5656>\
**Category:** Q&A\
**Created:** [December 26, 2024, 2:18pm UTC](https://forum.generic-mapping-tools.org/t/pen-style-not-work-for-map-grid-pen/5656 "2024-12-26T14:18:12Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![ZMAlt](https://yyz1.discourse-cdn.com/flex047/user_avatar/forum.generic-mapping-tools.org/zmalt/32/4912_2.png) [@ZMAlt](https://forum.generic-mapping-tools.org/u/ZMAlt)\
**Post date:** [December 26, 2024, 2:18pm UTC](https://forum.generic-mapping-tools.org/t/pen-style-not-work-for-map-grid-pen/5656/1 "2024-12-26T14:18:12Z")

</div>

Hi, everyone,

I found the pen style dose not work when set in `MAP_GRID_PEN`.

```bash
gmt basemap -Rd -JQ5i -Bafg --MAP_GRID_PEN=4p,black,dotted -png test1
gmt basemap -Rd -JQ5i -Bafg --MAP_GRID_PEN=4p,black -png test2

```

The first line gives this:

 ![test1](https://canada1.discourse-cdn.com/flex047/uploads/gmt/original/2X/9/996b3e1bb5145269874aba5511fc81ee14abce3a.png)

The second line gives:

 ![test2](https://canada1.discourse-cdn.com/flex047/uploads/gmt/original/2X/0/0c134eb6086df23c56d4081db408de65bb22746d.png)

---

<div class="post-metadata">

**Author:** ![Joaquim](https://yyz1.discourse-cdn.com/flex047/user_avatar/forum.generic-mapping-tools.org/joaquim/32/16_2.png) [@Joaquim](https://forum.generic-mapping-tools.org/u/Joaquim)\
**Post date:** [December 30, 2024, 8:20pm UTC](https://forum.generic-mapping-tools.org/t/pen-style-not-work-for-map-grid-pen/5656/2 "2024-12-30T20:20:22Z")

</div>

Can you please open an issue with this?

---

<div class="post-metadata">

**Author:** ![ZMAlt](https://yyz1.discourse-cdn.com/flex047/user_avatar/forum.generic-mapping-tools.org/zmalt/32/4912_2.png) [@ZMAlt](https://forum.generic-mapping-tools.org/u/ZMAlt)\
**Post date:** [December 31, 2024, 1:28am UTC](https://forum.generic-mapping-tools.org/t/pen-style-not-work-for-map-grid-pen/5656/3 "2024-12-31T01:28:17Z")

</div>

> <https://github.com/GenericMappingTools/gmt/issues/8647>
>
> The original post is \[here\](https://forum.generic-mapping-tools.org/t/pen-style-…not-work-for-map-grid-pen/5656).
> 
> \`\`\`
> gmt basemap -Rd -JQ5i -Bafg --MAP\_GRID\_PEN=4p,black,dotted -png test1
> gmt basemap -Rd -JQ5i -Bafg --MAP\_GRID\_PEN=4p,black -png test2
> \`\`\`
> The first line gives:
> !\[test1\](https://github.com/user-attachments/assets/2248287b-b6cc-44d4-9e29-aae60478e20e)
> 
> The second line gives:
> !\[test2\](https://github.com/user-attachments/assets/72dd8b89-0301-4dda-b7eb-7b781e564a06)
> 
> 
> 
> \*\*System information\*\*
> 
> \* Operating system: macos
> \* GMT version (\`gmt --version\`): gmt 6.5

---

<div class="post-metadata">

**Author:** ![Esteban82](https://yyz1.discourse-cdn.com/flex047/user_avatar/forum.generic-mapping-tools.org/esteban82/32/54_2.png) [@Esteban82](https://forum.generic-mapping-tools.org/u/Esteban82)\
**Post date:** [January 3, 2025, 4:35pm UTC](https://forum.generic-mapping-tools.org/t/pen-style-not-work-for-map-grid-pen/5656/4 "2025-01-03T16:35:51Z")

</div>

You can get your figure is you set the theme to classic. I think that the issue the modern mode uses the [auto theme](https://docs.generic-mapping-tools.org/dev/theme-settings.html).

`gmt basemap -Rd -JQ5i -Bafg --MAP_GRID_PEN=4p,black,dotted --GMT_THEME=classic -png test2`
