Do the grammar settings affect alignment? I would think alignment and importance would be independent of each other.
Announcement
Collapse
No announcement yet.
Grammar & alignment
Collapse
X
-
Hi MarkB,
Grammar can affect alignment within a line. BC3 will only align text that is of the same grammar type, so if you have a comment on the left and a string on the right BC will not match them up for comparison.
In the Grammar tab of File Formats, you can specify Line weights. These do affect how lines are aligned. This way you can specify certain text has a greater affect on alignment. For an example file format that uses line weights, look at the "Delphi Source" file format.Chris K Scooter Software
-
Thank you Chris.
1) If I have a grammar element that is unchecked (unimportant), will it still align based on that element? If not, what if I have a grammar element "Text in list:ABC" that is unimportant and a Line Weight "Text matching: ABC"? Which takes precedence - will it align on ABC?
2) I'm trying to show all the differences that are marked with 123456 or 987654 in the first 6 positions of a line. Any other differences I want to ignore. I can get it to show only the lines that are marked that way, but the alignment is off. I have the usual language verbs defined as a grammar element which is marked unimportant. I have ^123456 & ^987654 defined as important. I've added some language verbs as line weights, but it's still not aligning right. I'm not sure what I'm doing wrong.
Comment
-
Hello,
Firstly, order is important. If your files are out of order, BC3 will not sort them automatically to align on similar lines. BC3 will make alignments in order where it can, and the other lines will align in place (or be Orphan lines) in their relative positions.
Unimportant text will still align, but the differences can be Ignored. If you enable the option "Never Align Differences" then only Important text will be used in this case. This way you could use this option to only align lines that have Important sections that match, and other differences will be Unimportant/Blue with "Ignore Unimportant Differences" toggled off.
If you are still having trouble, you can email us at [email protected] with
1) a link back to this forum post
2) a pair of example files
3) your Support package zip (Help menu -> Support; Export)
4) a screenshot showing a misalignment in your example files (Show Line Numbers and Show Whitespace often help).Aaron P Scooter Software
Comment
Comment