tgjones / HlslTools

A Visual Studio extension that provides enhanced support for editing High Level Shading Language (HLSL) files
http://timjones.io/blog/archive/2016/04/25/hlsl-tools-for-visual-studio-v1.0-released
Other
561 stars 97 forks source link

Formatting of semantics #198

Closed chaoticbob closed 3 years ago

chaoticbob commented 3 years ago

This plug-in is amazing! It's has helped me trim down a a lot of development time for shaders. Thank you for making it.

I looked through the issues but I couldn't find this but I might have just missed. Is it possible to disable automatic formatting of semantics? I'm a bit pedantic about the alignment of semantics and keeping things readable.

Currently when the autoformatting turns this:

float4 Position : POSTION;
float3 Normal   : NORMAL;
float2 UV       : TEXCOORD;

into this:

float4 Position : POSTION;
float3 Normal : NORMAL;
float2 UV : TEXCOORD;

It's not the end of the world but it would be nice if the autoformatting either 1) didn't change this or 2) if there's an option for it to align on the :.

tgjones commented 3 years ago

Thank you for making it.

You're welcome!

This is a good feature suggestion. I'll have a think about which option makes the most sense, but making it optional somehow is definitely a good idea.

tgjones commented 3 years ago

I've added an option for this:

image

Arguably this "don't change" setting should be available for the other spacing options too.