general improvement

This commit is contained in:
Kyle
2020-07-04 15:56:59 -07:00
parent 6afa5dde54
commit 42f40084f8
2 changed files with 8 additions and 7 deletions

View File

@@ -37,7 +37,7 @@
<div onclick='toggleTabs(this, "watermarkTab")'>Watermark</div> <div onclick='toggleTabs(this, "watermarkTab")'>Watermark</div>
<div onclick='toggleTabs(this, "collectorTab")'>Collector</div> <div onclick='toggleTabs(this, "collectorTab")'>Collector</div>
<div onclick='toggleTabs(this, "importTab")'>Import</div> <div onclick='toggleTabs(this, "importTab")'>Import</div>
<div onclick='toggleTabs(this, "tutorialTab")'>Tutorial</div> <div onclick='{toggleTabs(this, "tutorialTab"); if (document.getElementById("tutorial").src == "") {document.getElementById("tutorial").src = "https://www.youtube.com/embed/UrNk6I55S0Q"}}'>Tutorial</div>
<!-- <div onclick='toggleTabs(this, "advancedTab")'>Advanced</div> --> <!-- <div onclick='toggleTabs(this, "advancedTab")'>Advanced</div> -->
</div> </div>
<div id='tabOptions'> <div id='tabOptions'>
@@ -138,7 +138,6 @@
<input type="text" placeholder="Via URL" onchange="setSymbol.src = 'https://cors-anywhere.herokuapp.com/' + this.value"> <input type="text" placeholder="Via URL" onchange="setSymbol.src = 'https://cors-anywhere.herokuapp.com/' + this.value">
<input type="text" id="inputSetCode" placeholder="Via Set Code" onchange="setSymbolFromGatherer()"> <input type="text" id="inputSetCode" placeholder="Via Set Code" onchange="setSymbolFromGatherer()">
<input type="text" id="inputSetRarity" placeholder="Rarity" onchange="setSymbolFromGatherer()"> <input type="text" id="inputSetRarity" placeholder="Rarity" onchange="setSymbolFromGatherer()">
<!-- <button class="button" onclick="randomSet()">Random</button> -->
</div> </div>
</div> </div>
<div id='watermarkTab' class='hidden'> <div id='watermarkTab' class='hidden'>
@@ -180,7 +179,7 @@
<input type="number" class="input number" id="inputCardNameNumberTextImport" onchange="inputCardNameNumberTextImport(this.value)" value="1" min="1" max="1"> <input type="number" class="input number" id="inputCardNameNumberTextImport" onchange="inputCardNameNumberTextImport(this.value)" value="1" min="1" max="1">
</div> </div>
<div id='tutorialTab' class='hidden' style='width: 100%; height: 56.25%;'> <div id='tutorialTab' class='hidden' style='width: 100%; height: 56.25%;'>
<iframe src="https://www.youtube.com/embed/UrNk6I55S0Q" width='1920' height='1080' allowfullscreen style='width: 100%; height:100%; border: none;'></iframe> <iframe width='1920' height='1080' allowfullscreen style='width: 100%; height:100%; border: none;' id='tutorial'></iframe>
</div> </div>
</div> </div>
<div class='downloadCardImage'> <div class='downloadCardImage'>
@@ -207,7 +206,7 @@
How You Can Help How You Can Help
</div> </div>
<div class="justify"> <div class="justify">
As a student on a tight budget, it can be hard to play Magic. If you've enjoyed using Card Conjurer and would like to help me attend a draft or buy a cool commander piece, you can make a small donatation via <a style='color: #3b7bbf;' href="https://www.paypal.me/kyleburtondonate" target='_blank'>PayPal</a>. As a student on a tight budget, it can be hard to afford Magic. If you've enjoyed using Card Conjurer and would like to help me attend a draft or buy a cool commander piece, you can make a small donatation via <a style='color: #3b7bbf;' href="https://www.paypal.me/kyleburtondonate" target='_blank'>PayPal</a>.
</div> </div>
</div> </div>
</div> </div>

View File

@@ -440,7 +440,8 @@ function writeText(textObjectList, targetContext) {
textLineContext.lineWidth = outlineThickness textLineContext.lineWidth = outlineThickness
textFont = textObjectList[i].font textFont = textObjectList[i].font
textLineContext.font = fontStyle + textSize + 'px ' + textFont textLineContext.font = fontStyle + textSize + 'px ' + textFont
textLineContext.fillStyle = textObjectList[i].fontColor var currentFontColor = textObjectList[i].fontColor
textLineContext.fillStyle = currentFontColor
var textX = textCanvasBuffer var textX = textCanvasBuffer
var textY = 0 var textY = 0
var currentLineWidth = 0 var currentLineWidth = 0
@@ -513,7 +514,8 @@ function writeText(textObjectList, targetContext) {
} else if (possibleCodeLower.includes('shadow')) { } else if (possibleCodeLower.includes('shadow')) {
shadow = parseInt(possibleCodeLower.replace('shadow', '')) shadow = parseInt(possibleCodeLower.replace('shadow', ''))
} else if (possibleCodeLower.includes('fontcolor')) { } else if (possibleCodeLower.includes('fontcolor')) {
textLineContext.fillStyle = possibleCodeLower.slice(9, possibleCodeLower.length) currentFontColor = possibleCodeLower.slice(9, possibleCodeLower.length)
textLineContext.fillStyle = currentFontColor
} else if (possibleCodeLower == 'artistbrush') { } else if (possibleCodeLower == 'artistbrush') {
var artistBrushWidth = textSize * 1.2 var artistBrushWidth = textSize * 1.2
textLineContext.drawImage(manaSymbolImageList[62], textX, textCanvasBuffer + textSize - artistBrushWidth * 0.58, artistBrushWidth, artistBrushWidth * 13 / 21) textLineContext.drawImage(manaSymbolImageList[62], textX, textCanvasBuffer + textSize - artistBrushWidth * 0.58, artistBrushWidth, artistBrushWidth * 13 / 21)
@@ -583,7 +585,7 @@ function writeText(textObjectList, targetContext) {
if (shadow > 0) { if (shadow > 0) {
textLineContext.fillStyle = 'black' textLineContext.fillStyle = 'black'
textLineContext.fillText(wordToWrite, textX + shadow, textCanvasBuffer + textSize + shadow) textLineContext.fillText(wordToWrite, textX + shadow, textCanvasBuffer + textSize + shadow)
textLineContext.fillStyle = textObjectList[i].fontColor textLineContext.fillStyle = currentFontColor
} }
if (outline != undefined) { if (outline != undefined) {
textLineContext.strokeText(wordToWrite, textX, textCanvasBuffer + textSize) textLineContext.strokeText(wordToWrite, textX, textCanvasBuffer + textSize)