XAlign
XAlign copied to clipboard
Aligned text block introduces extra newlines.
When I apply the align command on the following block:
const API::Resource::Key Version = API::Resource::Key::Generate("Core::Version");
const API::Resource::Key ProductName = API::Resource::Key::Generate("Core::ProductName");
const API::Resource::Key AuthorName = API::Resource::Key::Generate("Core::AuthorName");
const API::Resource::Key OrganisationName = API::Resource::Key::Generate("Core::OrganisationName");
The resulting aligned block will have extra newlines inserted:
const API::Resource::Key Version = API::Resource::Key::Generate("Core::Version");
const API::Resource::Key ProductName = API::Resource::Key::Generate("Core::ProductName");
const API::Resource::Key AuthorName = API::Resource::Key::Generate("Core::AuthorName");
const API::Resource::Key OrganisationName = API::Resource::Key::Generate("Core::OrganisationName");
The source file in question is in UTF-8 format, with Windows (CRLF) encoding.
Maybe this line is too long ?
const API::Resource::Key OrganisationName = API::Resource::Key::Generate("Core::OrganisationName");
The following may help:
Cancel the line-wrapping in Preferences -> Text Editing -> Indentation -> Line wrapping
, then try again.
i've got the same issue.... canceling line-wrap did not help i even get some extra lines when aligning short code lines
this defines:
#define make_int2 (int2)
#define make_float4 (float4)
#define make_float2 (float2)
#define make_ushort4 (ushort4)
#define make_float3 (float3)
#define make_ushort3 (ushort3)
become:
#define make_int2 (int2)
#define make_float4 (float4)
#define make_float2 (float2)
#define make_ushort4 (ushort4)
#define make_float3 (float3)
#define make_ushort3 (ushort3)
This is still an ongoing problem in the latest version.
Test file: https://www.dropbox.com/s/bbnnv3t54e25b77/test.zip?dl=0