rs.vertical_position.reference = TOP_OF_SCREEN;
break;
case dcp::VALIGN_CENTER:
- rs.vertical_position.reference = CENTRE_OF_SCREEN;
+ rs.vertical_position.reference = VERTICAL_CENTRE_OF_SCREEN;
break;
case dcp::VALIGN_BOTTOM:
rs.vertical_position.reference = BOTTOM_OF_SCREEN;
vertical_reference = TOP_OF_SCREEN;
break;
case 8:
- vertical_reference = CENTRE_OF_SCREEN;
+ vertical_reference = VERTICAL_CENTRE_OF_SCREEN;
break;
case 0:
vertical_reference = BOTTOM_OF_SCREEN;
case TOP_OF_SUBTITLE:
/* Nothing to do */
break;
- case CENTRE_OF_SCREEN:
+ case VERTICAL_CENTRE_OF_SCREEN:
current.vertical_position.proportional = current.vertical_position.proportional.get() - ((line_breaks + 1) * line_size) / 2;
break;
case BOTTOM_OF_SCREEN:
} else if (style == "\\an1" || style == "\\an2" || style == "\\an3") {
current.vertical_position.reference = sub::BOTTOM_OF_SCREEN;
} else if (style == "\\an4" || style == "\\an5" || style == "\\an6") {
- current.vertical_position.reference = sub::CENTRE_OF_SCREEN;
+ current.vertical_position.reference = sub::VERTICAL_CENTRE_OF_SCREEN;
} else if (style == "\\an7" || style == "\\an8" || style == "\\an9") {
current.vertical_position.reference = sub::TOP_OF_SCREEN;
}
case TOP_OF_SCREEN:
vp = rint (line.vertical_position.proportional.get() * ROWS);
break;
- case CENTRE_OF_SCREEN:
+ case VERTICAL_CENTRE_OF_SCREEN:
vp = rint (line.vertical_position.proportional.get() * ROWS + (ROWS / 2.0));
break;
case BOTTOM_OF_SCREEN:
case TOP_OF_SCREEN:
vp = prop * ROWS;
break;
- case CENTRE_OF_SCREEN:
+ case VERTICAL_CENTRE_OF_SCREEN:
vp = (prop + 0.5) * ROWS;
break;
case BOTTOM_OF_SCREEN:
switch (reference.get ()) {
case TOP_OF_SCREEN:
return prop;
- case CENTRE_OF_SCREEN:
+ case VERTICAL_CENTRE_OF_SCREEN:
return prop + 0.5;
case BOTTOM_OF_SCREEN:
return 1 - prop;
if (s == "top") {
return TOP_OF_SCREEN;
} else if (s == "center") {
- return CENTRE_OF_SCREEN;
+ return VERTICAL_CENTRE_OF_SCREEN;
} else if (s == "bottom") {
return BOTTOM_OF_SCREEN;
}
/** distance is from the top of the screen, positive moves down */
TOP_OF_SCREEN,
/** distance is from the centre of the screen, positive moves down */
- CENTRE_OF_SCREEN,
+ VERTICAL_CENTRE_OF_SCREEN,
/** distance is from the bottom of the screen, positive moves up */
BOTTOM_OF_SCREEN,
/** position on screen is not known, so we are referring
SUB_END ();
SUB_START (sub::Time::from_hms (0, 0, 9, 260), sub::Time::from_hms (0, 0, 11, 560));
- LINE (0, sub::CENTRE_OF_SCREEN);
+ LINE (0, sub::VERTICAL_CENTRE_OF_SCREEN);
BLOCK("middle left", "Arial", 20, false, false, false);
SUB_END ();
SUB_START (sub::Time::from_hms (0, 0, 9, 270), sub::Time::from_hms (0, 0, 11, 560));
- LINE (0, sub::CENTRE_OF_SCREEN);
+ LINE (0, sub::VERTICAL_CENTRE_OF_SCREEN);
BLOCK("middle centre", "Arial", 20, false, false, false);
SUB_END ();
SUB_START (sub::Time::from_hms (0, 0, 9, 280), sub::Time::from_hms (0, 0, 11, 560));
- LINE (0, sub::CENTRE_OF_SCREEN);
+ LINE (0, sub::VERTICAL_CENTRE_OF_SCREEN);
BLOCK("middle right", "Arial", 20, false, false, false);
SUB_END ();
a.proportional = 0.7;
a.reference = sub::TOP_OF_SCREEN;
b.proportional = 0.3;
- b.reference = sub::CENTRE_OF_SCREEN;
+ b.reference = sub::VERTICAL_CENTRE_OF_SCREEN;
BOOST_CHECK (a < b);
a.proportional = 0.9;
case TOP_OF_SCREEN:
cout << "top";
break;
- case CENTRE_OF_SCREEN:
+ case VERTICAL_CENTRE_OF_SCREEN:
cout << "centre";
break;
case BOTTOM_OF_SCREEN: