Skip to content
Snippets Groups Projects

Update POM, add XLS head generation

Merged Thomas MUSSET requested to merge add-xls-header into master
2 files
+ 36
26
Compare changes
  • Side-by-side
  • Inline
Files
2
@@ -238,7 +238,9 @@ public class TrackProcessorMSD extends PluginTrackManagerProcessor implements Ac
if (useRealScalesBox.isSelected())
{
int cnt = 0;
int row = 0;
int row = 1; // Start from 1 because of table head
int cols = 0;
for (TrackSegment ts : trackPool.getTrackSegmentList())
{
// Better to allow partially clipped tracks otherwise we cannot get MSD for them (Stephane)
@@ -249,6 +251,10 @@ public class TrackProcessorMSD extends PluginTrackManagerProcessor implements Ac
if (msd.length > 0)
{
// Get max cols for the table
if (msd.length > cols)
cols = msd.length;
System.out.println("track " + cnt);
if (page != null)
@@ -268,11 +274,22 @@ public class TrackProcessorMSD extends PluginTrackManagerProcessor implements Ac
}
}
}
// Write table head
if (page != null) {
XLSUtil.setCellString(page, 0, 0, "frame");
if (cols > 0) {
for (int c = 0; c < cols; c++) {
XLSUtil.setCellString(page, c+1, 0, String.valueOf(c));
}
}
}
}
else
{
int cnt = 0;
int row = 0;
int row = 1; // Start from 1 because of table head
int cols = 0;
for (TrackSegment ts : trackPool.getTrackSegmentList())
{
@@ -284,6 +301,10 @@ public class TrackProcessorMSD extends PluginTrackManagerProcessor implements Ac
if (msd.length > 0)
{
// Get max cols for the table
if (msd.length > cols)
cols = msd.length;
System.out.println("track " + cnt);
if (page != null)
@@ -302,6 +323,16 @@ public class TrackProcessorMSD extends PluginTrackManagerProcessor implements Ac
}
}
}
// Write table head
if (page != null) {
XLSUtil.setCellString(page, 0, 0, "frame");
if (cols > 0) {
for (int c = 0; c < cols; c++) {
XLSUtil.setCellString(page, c+1, 0, String.valueOf(c));
}
}
}
}
if (workbook != null)
Loading