Skip to content

Commit

Permalink
30/03/2021
Browse files Browse the repository at this point in the history
  • Loading branch information
psalguerog committed Mar 30, 2021
1 parent dee2083 commit 48feea1
Show file tree
Hide file tree
Showing 8 changed files with 2,827 additions and 6 deletions.
29 changes: 27 additions & 2 deletions AnnotationSymbols.java
Original file line number Diff line number Diff line change
Expand Up @@ -1097,7 +1097,13 @@ private SymbolExtensionInfo drawBlock(SymbolDef symdef, GraphicsContext gc, doub
(int)Math.floor((seqAlign.getXlatedPos(sd.end)+2)/3)));
}
ArrayList<double[]> lstBlocks = new ArrayList<>();


if(entry.source.equals("PAR-clip"))
System.out.println("strseg es demasiado grande comparado con utrsite");

if(entry.source.equals("UTRsite"))
System.out.println("Ver porqué todo 0s");

int endseg;
double x, width;
double mult = viewer.getViewType(viewer.getClass().toString()).equals(ViewAnnotation.Views.PROTEIN)? 3.0 : 1.0;
Expand All @@ -1108,7 +1114,7 @@ private SymbolExtensionInfo drawBlock(SymbolDef symdef, GraphicsContext gc, doub
boolean done = false;
SymbolExtensionInfo sei = new SymbolExtensionInfo(0, 0, 0, 0);
for(SeqAlign.Position pos : posList) {
if(!done && strseg >= pos.start && strseg <= pos.end) {
if((!done && strseg >= pos.start && strseg <= pos.end)){ // || entry.source.equals("PAR-clip")) {
done = true;
endseg = endpos;
if(endpos > pos.end) {
Expand Down Expand Up @@ -1136,6 +1142,25 @@ private SymbolExtensionInfo drawBlock(SymbolDef symdef, GraphicsContext gc, doub
// set for next segment if spanning across gap
if(!done)
strseg = (int)Math.floor(seqAlign.getAlignedPos((entry.strpos + totalWidth) * mult, tgexonsList)/mult);
}else{ //color blocks with other size
done = true;
totalWidth += (entry.dspendpos - entry.dspstrpos + 1);
width = entry.dspendpos - entry.dspstrpos + 1;
x = viewer.adjustX(xi + (entry.dspstrpos - geneEntry.strpos + 1) * ppb);
if(sei.minX == 0 || sei.minX > x)
sei.minX = x;
width *= ppb;
double x2 = x + width;
if(sei.maxX == 0 || sei.maxX < x2)
sei.maxX = x2;
double ys = viewer.adjustY(y);
ys += symdef.height/2;
sei.y = ys;
double[] block = new double[3];
block[0] = x;
block[1] = y;
block[2] = width;
lstBlocks.add(block);
}
}

Expand Down
2 changes: 1 addition & 1 deletion SubTabBase.java
Original file line number Diff line number Diff line change
Expand Up @@ -825,7 +825,7 @@ protected void setTableSearchActive(TableView tbl, boolean value) {
}
else {
tbl.getStyleClass().removeAll("search-active");
tbl.setStyle("-fx-background-color: #FFFFF0;");
tbl.setStyle("-fx-background-color: #FFFFF;");
}
}
protected void setTableFiltered(TableView tbl, boolean filtered) {
Expand Down
2 changes: 1 addition & 1 deletion Tappas.java
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ public class Tappas extends Application {
public static final String APP_NAME = "tappas";
public static final int APP_MAJOR_VER = 1;
public static final int APP_MINOR_VER = 0;
public static final int APP_STRREV = 6;
public static final int APP_STRREV = 7;
public static final String RES_VER_FILE = "resource_v" + APP_MAJOR_VER + "." + APP_MINOR_VER + "." + APP_STRREV + ".txt";
public static final String APP_LOCK_FILE = ".tappas.lock.prm";
public static final String APP_PORT_PARAM = "port";
Expand Down
Loading

0 comments on commit 48feea1

Please sign in to comment.