diff --git a/apps/argparse/argparse.hpp b/apps/argparse/argparse.hpp index 029fa03c2c42..8137745a576a 100644 --- a/apps/argparse/argparse.hpp +++ b/apps/argparse/argparse.hpp @@ -2147,7 +2147,8 @@ class ArgumentParser { } } cur_mutex = arg_mutex; - if (curline.size() + 1 + arg_inline_usage.size() > + if (curline.size() != indent_size && + curline.size() + 1 + arg_inline_usage.size() > this->m_usage_max_line_width) { stream << curline << std::endl; curline = std::string(indent_size, ' '); diff --git a/apps/gdalargumentparser.cpp b/apps/gdalargumentparser.cpp index 3b795325345b..f7e037827739 100644 --- a/apps/gdalargumentparser.cpp +++ b/apps/gdalargumentparser.cpp @@ -25,7 +25,7 @@ GDALArgumentParser::GDALArgumentParser(const std::string &program_name, bool bForBinary) : ArgumentParser(program_name, "", default_arguments::none) { - set_usage_max_line_width(120); + set_usage_max_line_width(80); set_usage_break_on_mutex(); add_usage_newline(); diff --git a/doc/source/programs/gdal_translate.rst b/doc/source/programs/gdal_translate.rst index 79a75d14cf36..5b16b9111f0c 100644 --- a/doc/source/programs/gdal_translate.rst +++ b/doc/source/programs/gdal_translate.rst @@ -15,29 +15,36 @@ Synopsis .. code-block:: + gdal_translate [--help] [--long-usage] [--help-general] + [-ot Byte|Int8|[U]Int{16|32|64}|CInt{16|32}|[C]Float{32|64}] + [-if ]... [-of ] [--quiet] + [-b ]... [-mask ] [-expand gray|rgb|rgba] + [[-strict]|[-not_strict]] + [-outsize ] [-tr ] + [-ovr |AUTO|AUTO-|NONE] [-sds] + [-r nearest,bilinear,cubic,cubicspline,lanczos,average,mode] + [[-scale [ [ ]]]...| + [-scale_X [ [ ]]]...| + [-unscale]] + [[-exponent ]|[-exponent_X ]...] + [-srcwin ] + [-projwin ] + [-projwin_srs ] [-epo] [-eco] [-a_srs ] + [-a_coord_epoch ] [-a_ullr ] + [-a_nodata |none] + [-a_gt ] + [-a_scale ] [-a_offset ] [-nogcp] + [-gcp []]... + [-colorinterp {red|green|blue|alpha|gray|undefined|pan| + coastal|rededge|nir|swir|mwir|lwir|...},...] + [-colorinterp_X {red|green|blue|alpha|gray|undefined|pan| + coastal|rededge|nir|swir|mwir|lwir|...}]... + [[-stats]|[-approx_stats]] + [-norat] [-noxmp] [-co =]... + [-mo =]... [-dmo :=]... + [-oo =]... + - gdal_translate [--help] [--help-general] [--long-usage] - [-ot {Byte/Int8/Int16/UInt16/UInt32/Int32/UInt64/Int64/Float32/Float64/ - CInt16/CInt32/CFloat32/CFloat64}] [-strict] - [-if ]... [-of ] - [-b ] [-mask ] [-expand {gray|rgb|rgba}] - [-outsize [%]|0 [%]|0] [-tr ] - [-ovr |AUTO|AUTO-|NONE] - [-r {nearest,bilinear,cubic,cubicspline,lanczos,average,mode}] - [-unscale] [-scale[_bn] [ [ ]]]... [-exponent[_bn] ]... - [-srcwin ] [-epo] [-eco] - [-projwin ] [-projwin_srs ] - [-a_srs ] [-a_coord_epoch ] - [-a_ullr ] [-a_nodata ] - [-a_gt ] - [-a_scale ] [-a_offset ] - [-nogcp] [-gcp []]... - |-colorinterp{_bn} {red|green|blue|alpha|gray|undefined|pan|coastal|rededge|nir|swir|mwir|lwir|...}] - |-colorinterp {red|green|blue|alpha|gray|undefined|pan|coastal|rededge|nir|swir|mwir|lwir|...},...] - [-mo =]... [-dmo "DOMAIN:META-TAG=VALUE"]... [-q] [-sds] - [-co =]... [-stats] [-norat] [-noxmp] - [-oo =]... - Description ----------- diff --git a/doc/source/programs/gdaladdo.rst b/doc/source/programs/gdaladdo.rst index 41686cbeccc2..9745d046a01f 100644 --- a/doc/source/programs/gdaladdo.rst +++ b/doc/source/programs/gdaladdo.rst @@ -16,7 +16,8 @@ Synopsis .. code-block:: gdaladdo [--help] [--help-general] - [-r {nearest|average|rms|gauss|bilinear|cubic|cubicspline|lanczos|average_mp|average_magphase|mode}] + [-r {nearest|average|rms|gauss|bilinear|cubic|cubicspline| + lanczos|average_mp|average_magphase|mode}] [-ro] [-clean] [-q] [-oo =]... [-minsize ] [--partial-refresh-from-source-timestamp] [--partial-refresh-from-projwin ] diff --git a/doc/source/programs/gdalbuildvrt.rst b/doc/source/programs/gdalbuildvrt.rst index 509fd52f91d6..26fcd5122e54 100644 --- a/doc/source/programs/gdalbuildvrt.rst +++ b/doc/source/programs/gdalbuildvrt.rst @@ -15,23 +15,23 @@ Synopsis .. code-block:: - gdalbuildvrt [--help] [--help-general] - [-tileindex ] - [-resolution {highest|lowest|average|user}] - [-te ] [-tr ] [-tap] - [-separate] [-b ]... [-sd ] - [-allow_projection_difference] [-q] - [-addalpha] [-hidenodata] - [-srcnodata "[ ]..."] [-vrtnodata "[ ]..." - [-ignore_srcmaskband] - [-nodata_max_mask_threshold ] - [-a_srs ] - [-r {nearest|bilinear|cubic|cubicspline|lanczos|average|mode}] - [-oo =]... - [-co =]... - [-input_file_list ] [-overwrite] - [-strict | -non_strict] - []... + gdalbuildvrt [--help] [--long-usage] [--help-general] + [--quiet] + [[-strict]|[-non_strict]] + [-tile_index ] + [-resolution user|average|highest|lowest] [-tr ] + [-input_file_list ] [-separate] + [-allow_projection_difference] [-sd ] [-tap] + [-te ] [-addalpha] [-b ]... + [-hidenodata] [-overwrite] + [-srcnodata "[ ]..."] + [-vrtnodata "[ ]..."] [-a_srs ] + [-r nearest|bilinear|cubic|cubicspline|lanczos|average|mode] + [-oo =]... [-co =]... + [-ignore_srcmaskband] + [-nodata_max_mask_threshold ] + []... + Description ----------- diff --git a/doc/source/programs/gdalwarp.rst b/doc/source/programs/gdalwarp.rst index 83a4e7d78241..5c915c39d9a2 100644 --- a/doc/source/programs/gdalwarp.rst +++ b/doc/source/programs/gdalwarp.rst @@ -16,33 +16,31 @@ Synopsis .. code-block:: gdalwarp [--help] [--long-usage] [--help-general] - [--quiet] [-overwrite] [-of ] [-co =]... - [-s_srs ] [-t_srs ] + [--quiet] [-overwrite] [-of ] + [-co =]... [-s_srs ] [-t_srs ] [[-srcalpha]|[-nosrcalpha]] [-dstalpha] [-tr |square] [-ts ] - [-te ] - [-r near|bilinear|cubic|cubicspline|lanczos|average|rms|mode|min|max|med|q1|q3|sum] + [-te ] [-te_srs ] + [-r near|bilinear|cubic|cubicspline|lanczos|average|rms|mode| + min|max|med|q1|q3|sum] [-ot Byte|Int8|[U]Int{16|32|64}|CInt{16|32}|[C]Float{32|64}] ... Advanced options: - [-wo =]... [-multi] - [-s_coord_epoch ] [-t_coord_epoch ] [-ct ] + [-wo =]... [-multi] [-s_coord_epoch ] + [-t_coord_epoch ] [-ct ] [[-tps]|[-rpc]|[-geoloc]] [-order <1|2|3>] [-refine_gcps []] - [-to =]... - [-et ] [-wm ] - [-srcnodata "[ ]..."] + [-to =]... [-et ] + [-wm ] [-srcnodata "[ ]..."] [-dstnodata "[ ]..."] [-tap] [-wt Byte|Int8|[U]Int{16|32|64}|CInt{16|32}|[C]Float{32|64}] [-cutline |] [-cutline_srs ] [-cwhere ] [[-cl ]|[-csql ]] - [-cblend ] [-crop_to_cutline] - [-nomd] [-cvmd ] [-setci] - [-oo =]... [-doo =]... - [-ovr |AUTO|AUTO-|NONE] + [-cblend ] [-crop_to_cutline] [-nomd] + [-cvmd ] [-setci] [-oo =]... + [-doo =]... [-ovr |AUTO|AUTO-|NONE] [[-vshift]|[-novshiftgrid]] [-if ]... [-srcband ]... [-dstband ]... diff --git a/doc/source/programs/ogrinfo.rst b/doc/source/programs/ogrinfo.rst index ff66c9ab15c0..e709c0839892 100644 --- a/doc/source/programs/ogrinfo.rst +++ b/doc/source/programs/ogrinfo.rst @@ -16,17 +16,19 @@ Synopsis .. code-block:: - ogrinfo [--help] [--help-general] - [-if ] [-json] [-ro] [-q] [-where |@] - [-spat ] [-geomfield ] [-fid ] - [-sql |@] [-dialect ] [-al] [-rl] - [-so|-features] [-limit ] [-fields={YES|NO}]] - [-geom={YES|NO|SUMMARY|WKT|ISO_WKT}] [-oo =]... - [-nomd] [-listmdd] [-mdd |all]... - [-nocount] [-nogeomtype] [[-noextent] | [-extent3D]] - [-wkt_format WKT1|WKT2|] - [-fielddomain ] - [ [ ...]] + ogrinfo [--help] [--long-usage] [--help-general] + [-json] [-ro] [-update] [--quiet] [-fid ] + [-spat ] [-geomfield ] + [-where ] + [[-sql ]|[-rl]] + [-dialect ] [-al] + [[-summary]|[-features]] + [-limit ] [-fields YES|NO] + [-geom YES|NO|SUMMARY|WKT|ISO_WKT] [-oo ]... [-nomd] + [-listmdd] [-mdd ]... [-nocount] [-noextent] [-extent3D] + [-nogeomtype] [-wkt_format WKT1|WKT2|WKT2_2015|WKT2_2019] + [-fielddomain ] [-if ]... + filename []... Description -----------