Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Text align preferences added on Lyrics Mobile Server #147

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions Quelea/languages/pl.lang
Original file line number Diff line number Diff line change
Expand Up @@ -320,7 +320,7 @@ setup.oo.failed.title=Błąd inicjalizacji OpenOffice
use.oo.label=Używaj OpenOffice do prezentacji (eksperymentanie)
oo.path=Ścieżka do programu OpenOffice
browse=Przeglądaj...
loading.text=Ładowanie
loading.text=Trwa ładowanie
building.bible.index=Ładowanie biblii
bible.search.title=Wyszukiwacz biblii
initial.search.text=<Wprowadź tekst do wyszukania>
Expand Down Expand Up @@ -428,7 +428,7 @@ max.font.size.label=Maksymalny rozmiar fontu
thumbnail.size.label=Rozmiar miniatur
additional.line.spacing.label=Dodatkowy odstęp między liniami
logo.screen.tooltip=Lewe kliknięcie wyświetla - Prawe kliknięcie wybiera grafikę
change.graphics.label=Zmiana wyglądu
change.graphics.label=Ustawienia wyświetlania
font.colour.label=Kolor fontu
background.colour.label=Kolor tła
mobile.lyrics.heading=Mobile Lyrics
Expand Down
14 changes: 14 additions & 0 deletions Quelea/server/defaultpage.htm
Original file line number Diff line number Diff line change
Expand Up @@ -98,6 +98,7 @@
color: #111111;
font-family:"Helvetica";
font-weight:bold;
text-align: left;
}
</style>
<script type="text/javascript" src="jscolor.js"></script>
Expand Down Expand Up @@ -165,6 +166,11 @@
}
}
}
var textalign = getCookie("textalign");
if (!textalign) {
textalign = 'left';
}
document.getElementById('dynamicDiv').style.textAlign = textalign;
var fontcolor = getCookie("fontcolor");
if (!fontcolor) {
fontcolor = '#000000';
Expand Down Expand Up @@ -300,6 +306,14 @@
<div>
<a href="#close" title="Close" class="close">X</a>
<h2>[change.graphics.label]</h2>

<div><p>[line.alignment.label]: <select id="selectAlignment" onchange="javascript:document.getElementById('dynamicDiv').style.textAlign = document.getElementById('selectAlignment').value;
setCookie('textalign', document.getElementById('selectAlignment').value, 100);">
<option value="left">[left]</option>
<option value="center">[centre]</option>
<option value="right">[right]</option>
</select></p></div>

<div><p>[font.colour.label]: <input id="font-color" type="text" readonly class="color" onchange="javascript:document.getElementById('dynamicDiv').style.color = '#' + document.getElementById('font-color').value;
setCookie('fontcolor', '#' + document.getElementById('font-color').value, 100);"></p></div>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -126,6 +126,10 @@ public boolean isRunning() {

private String sortLabels(String content) {
content = content.replace("[loading.text]", LabelGrabber.INSTANCE.getLabel("loading.text"));
content = content.replace("[line.alignment.label]", LabelGrabber.INSTANCE.getLabel("stage.line.alignment"));
content = content.replace("[left]", LabelGrabber.INSTANCE.getLabel("left"));
content = content.replace("[centre]", LabelGrabber.INSTANCE.getLabel("centre"));
content = content.replace("[right]", LabelGrabber.INSTANCE.getLabel("right"));
content = content.replace("[font.colour.label]", LabelGrabber.INSTANCE.getLabel("font.colour.label"));
content = content.replace("[background.colour.label]", LabelGrabber.INSTANCE.getLabel("background.colour.label"));
content = content.replace("[change.graphics.label]", LabelGrabber.INSTANCE.getLabel("change.graphics.label"));
Expand Down