Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow -l for auto-legends in events #6182

Merged
merged 2 commits into from Jan 3, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
4 changes: 4 additions & 0 deletions doc/rst/source/events.rst
Expand Up @@ -43,6 +43,7 @@ Synopsis
[ |SYN_OPT-f| ]
[ |SYN_OPT-h| ]
[ |SYN_OPT-i| ]
[ |SYN_OPT-l| ]
[ |SYN_OPT-p| ]
[ |SYN_OPT-qi| ]
[ |SYN_OPT-w| ]
Expand Down Expand Up @@ -301,6 +302,9 @@ Optional Arguments

.. include:: explain_-icols.rst_

.. |Add_-l| unicode:: 0x20 .. just an invisible code
.. include:: explain_-l.rst_

.. |Add_perspective| unicode:: 0x20 .. just an invisible code
.. include:: explain_perspective.rst_

Expand Down
8 changes: 4 additions & 4 deletions src/psevents.c
Expand Up @@ -31,7 +31,7 @@
#define THIS_MODULE_PURPOSE "Plot event symbols, lines, polygons and labels for one moment in time"
#define THIS_MODULE_KEYS "<D{,CC(,>?}"
#define THIS_MODULE_NEEDS "JR"
#define THIS_MODULE_OPTIONS "-:>BJKOPRUVXYabdefhipqw"
#define THIS_MODULE_OPTIONS "-:>BJKOPRUVXYabdefhilpqw"

enum Psevent { /* Misc. named array indices */
PSEVENTS_SYMBOL = 0,
Expand Down Expand Up @@ -185,8 +185,8 @@ static int usage (struct GMTAPI_CTRL *API, int level) {
GMT_Usage (API, 0, "usage: %s [<table>] %s %s -T<now> [-Ar[<dpu>[c|i][+z[<z>]]]|s] [%s] [-C<cpt>] [-D[j|J]<dx>[/<dy>][+v[<pen>]]] "
"[-E[s|t][+o|O<dt>][+r<dt>][+p<dt>][+d<dt>][+f<dt>][+l<dt>]] [-F[+a<angle>][+f<font>][+r[<first>]|+z[<fmt>]][+j<justify>]] "
"[-G<fill>] [-H<labelinfo>] [-L[t|<length>]] [-Mi|s|t|z<val1>[+c<val2]] [-N[c|r]] [-Q<prefix>] [-S<symbol>[<size>]] [%s] [%s] [-W[<pen>]] [%s] [%s] [-Z\"<command>\"] "
"[%s] [%s] %s[%s] [%s] [%s] [%s] [%s] [%s] [%s] [%s] [%s]\n", name, GMT_J_OPT, GMT_Rgeoz_OPT, GMT_B_OPT, GMT_U_OPT, GMT_V_OPT, GMT_X_OPT, GMT_Y_OPT, GMT_a_OPT, GMT_b_OPT,
API->c_OPT, GMT_d_OPT, GMT_e_OPT, GMT_f_OPT, GMT_h_OPT, GMT_i_OPT, GMT_qi_OPT, GMT_w_OPT, GMT_colon_OPT, GMT_PAR_OPT);
"[%s] [%s] %s[%s] [%s] [%s] [%s] [%s] [%s] [%s] [%s] [%s] [%s]\n", name, GMT_J_OPT, GMT_Rgeoz_OPT, GMT_B_OPT, GMT_U_OPT, GMT_V_OPT, GMT_X_OPT, GMT_Y_OPT, GMT_a_OPT, GMT_b_OPT,
API->c_OPT, GMT_d_OPT, GMT_e_OPT, GMT_f_OPT, GMT_h_OPT, GMT_i_OPT, GMT_l_OPT, GMT_qi_OPT, GMT_w_OPT, GMT_colon_OPT, GMT_PAR_OPT);

if (level == GMT_SYNOPSIS) return (GMT_MODULE_SYNOPSIS);

Expand Down Expand Up @@ -270,7 +270,7 @@ static int usage (struct GMTAPI_CTRL *API, int level) {
GMT_Usage (API, -2, "Append core external <command> and required options that must include -S<format><size>. "
"The quoted <command> must start with [ps]coupe, [ps]meca, or [ps]velo. "
"(Note: The <command> cannot contain options -C, -G, -I, -J, -N, -R, -W, -t).");
GMT_Option (API, "a,bi2,c,di,e,f,h,i,p,qi,w,:,.");
GMT_Option (API, "a,bi2,c,di,e,f,h,i,l,p,qi,w,:,.");

return (GMT_MODULE_USAGE);
}
Expand Down