Skip to content

Weird behavior of transparent outlines for superscripts and subscripts  #5481

Closed

Description

@uleysky

Test code:

#!/bin/bash
MAP="-R0/1/0/1 -JX10c"
echo -e "0 0\n1 0\n1 1\n0 1\n0 0" | gmt psxy $MAP -Gblack -P -K>test.ps
echo "0.5 0.6 0% transparency outline" | gmt pstext $MAP -F+jCM+f16p,Times-Bold,red=~4p,white -P -O -K>>test.ps
# Bug command
echo "0.5 0.5 a@+1@+b@+2@+c@+3@+d@+4@+e@+5@+f@+6@+g@+7@+h@+8@+i@+9@+j@+0@+" | gmt pstext $MAP -F+jCM+f16p,Times-Bold,red=~4p,white@90 -P -O -K>>test.ps
# What 90% transparency should look like
echo "0.5 0.4 90% transparency outline" | gmt pstext $MAP -F+jCM+f16p,Times-Bold,red=~4p,white@90 -P -O>>test.ps

Result:
test

This is probably a ghostscript bug, not a GMT. Ghostscript is 9.54.0.

Activity

  1. added
    bug
    on Jul 14, 2021
  2. PaulWessel commented on Jul 14, 2021

    @PaulWessel
    Contributor

    Might be GMT bug, will have a look after vacation.

  3. self-assigned this
    on Jul 14, 2021
  4. added this to the milestone on Sep 22, 2021
  5. uleysky commented on Feb 21, 2022

    @uleysky
    ContributorAuthor

    Any progress?

  6. PaulWessel commented on Feb 21, 2022

    @PaulWessel
    Contributor

    No, sorry, got forgotten. I will see if I can have a look tomorrow. Busy week then off traveling...But my theory is that the superscript pieces (which are set separately) somehow keeps adding up the transparency.

  7. modified the milestones: , 6.5.0 on Jun 25, 2022
  8. modified the milestones: 6.5.0, 6.6.0 on Jan 7, 2024
  9. joa-quim commented on May 28, 2026

    @joa-quim
    Member

    With #9046 we get this

    echo 0.5 0.5 a@+1@+b@+2@+c@+3@+d@+4@+e@+5@+f@+6@+g@+7@+h@+8@+i@+9@+j@+0@+ | gmt pstext -R0/1/0/1 -JX10c -F+jCM+f16p,Times-Bold,red=~4p,black@90 -png lixo
    
    Image
  10. uleysky commented on May 28, 2026

    @uleysky
    ContributorAuthor

    Yes, the patch is working, at least for the test case.

  11. joa-quim commented on May 28, 2026

    @joa-quim
    Member

    OkK, thanks.

  12. Esteban82 commented on May 28, 2026

    @Esteban82
    Member

    It works for me too.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

bug

Type

No type

Projects

No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions