Skip to content
Merged
Show file tree
Hide file tree
Changes from all 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
108 changes: 45 additions & 63 deletions _content/windows/index.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,172 +2,154 @@
require_once _KEYMANCOM_INCLUDES . '/includes/template.php';
require_once _KEYMANCOM_INCLUDES . '/autoload.php';

use Keyman\Site\com\keyman\Locale;

Locale::definePageScope('LOCALE_WINDOWS', 'windows');

// Required
head([
'title' =>'Keyman for Windows ' . $stable_version,
'description' => 'Keyman for Windows',
'title' => _m_Windows('page_title', $stable_version),
'description' => _m_Windows('page_description'),
'css' => ['template.css','index.css','desktop.css','feature-grid.css'],
'showMenu' => true,
'banner' => [
'title' => 'Keyman '.$stable_version.' for Windows<br/><span id="title-small">Type in your language</span>',
'title' => _m_Windows('page_banner_title', $stable_version) . '<br/><span id="title-small">' . _m_Windows('page_banner_subtext') . '</span>',
'button' => '<div id="banner-buttons"><a class="banner-button" href="download"><img src="'.cdn('img/download_button.png').'" /></a></div>',
'image' => 'screenshots/14/windows/osk-malayalam-566x226.png',
'background' => 'water'
]
]);
?>
<br/>
<h2 class="red underline">Introducing Keyman <?= $stable_version; ?> for Windows</h2>
<p>
With keyboards for over 2500 languages, Keyman for Windows lets you type in your language even when Windows doesn't. You can even create your own custom keyboards with <a href="../developer/">Keyman Developer <?= $stable_version; ?></a>.
</p>
<p>
Our unique virtual keyboard technology makes it easy to type in all your programs, including Microsoft Office, Adobe Creative Suite, internet browsers and more, as well as supporting the latest version of Windows.
</p>
<p>
With nearly 30 years of development history, Keyman <?= $stable_version; ?> for Windows is the easiest and most efficient version to use we've ever built.
And now that Keyman is free, we've completely removed any obstacles from getting you typing right away.
</p>
<h2 class="red underline"><?= _m_Windows('intro_heading', $stable_version); ?></h2>
<?= _m_Windows('intro_paras', $stable_version); ?>
<ul>
<li><a href="features">See the features</a></li>
<li><a href="keyboards">Clever keyboards</a></li>
<li><a href="features"><?= _m_Windows('see_the_features') ?></a></li>
<li><a href="keyboards"><?= _m_Windows('clever_keyboards') ?></a></li>
</ul>
<div class="button-div">
<a href="download"><img src="<?php echo cdn('img/download_button.png'); ?>" /></a>
</div>

<?php
if (betaTier()) {
?>
<p>Want to try the Keyman for Windows <?php echo $beta_version ?> Beta? <a href="../beta/">Learn more</a></p>
<?php
}
if (betaTier()) {
echo "<p>{$_m_Windows('try_beta', $beta_version)}</p>";
}
?>

<h2 class="red underline">Features</h2>
<h2 class="red underline"><?= _m_Windows('features_heading') ?></h2>
<p>
Keyman is now free and open source.
<?= _m_Windows('keyman_is_free') ?>
</p>
<table class='feature-grid'>
<thead>
<tr>
<th>Feature</th>
<th><?= _m_Windows('feature_column') ?></th>
</tr>
</thead>
<tbody>
<tr>
<td><a href="features#keyboard-list">World-leading input methods for thousands of languages</a></td>
<td><a href="features#keyboard-list"><?= _m_Windows('world_leading_im') ?></a></td>
<td><img class="table-tick" src="<?php echo cdn("img/table-tick.png"); ?>"/></td>
</tr>
<tr>
<td><a href="features#keyman-dev">Create your own custom keyboards</a></td>
<td><a href="features#keyman-dev"><?= _m_Windows('create_custom_keyboards') ?></a></td>
<td><img class="table-tick" src="<?php echo cdn("img/table-tick.png"); ?>"/></td>
</tr>
<tr>
<td>Start on Windows Login option</td>
<td><?= _m_Windows('start_with_windows_login') ?></td>
<td><img class="table-tick" src="<?php echo cdn("img/table-tick.png"); ?>"/></td>
</tr>
<tr>
<td><a href="features#keyboard-limit">Number of keyboards you can install</a></td>
<td>Unlimited</td>
<td><a href="features#keyboard-limit"><?= _m_Windows('number_of_keyboards_install') ?></a></td>
<td><?= _m_Windows('keyboards_unlimited') ?></td>
</tr>
<tr>
<td><a href="features#language-association">Associate keyboards with multiple languages</a></td>
<td><a href="features#language-association"><?= _m_Windows('associate_keyboards') ?></a></td>
<td><img class="table-tick" src="<?php echo cdn("img/table-tick.png"); ?>"/></td>
</tr>
<tr>
<td><a href="features#keyboard-information">Advanced keyboard information</a></td>
<td><a href="features#keyboard-information"><?= _m_Windows('advanced_keyboard_info') ?></a></td>
<td><img class="table-tick" src="<?php echo cdn("img/table-tick.png"); ?>"/></td>
</tr>
<tr>
<td><a href="features#hotkeys">Keyboard hotkeys</a></td>
<td><a href="features#hotkeys"><?= _m_Windows('keyboard_hotkeys') ?></a></td>
<td><img class="table-tick" src="<?php echo cdn("img/table-tick.png"); ?>"/></td>
</tr>
<tr>
<td><a href="features#hotkeys">Interface hotkeys</a></td>
<td><a href="features#hotkeys"><?= _m_Windows('interface_hotkeys') ?></a></td>
<td><img class="table-tick" src="<?php echo cdn("img/table-tick.png"); ?>"/></td>
</tr>
<tr>
<td><a href="features#language-switcher">Language switcher</a></td>
<td><a href="features#language-switcher"><?= _m_Windows('language_switcher') ?></a></td>
<td><img class="table-tick" src="<?php echo cdn("img/table-tick.png"); ?>"/></td>
</tr>
<tr>
<td><a href="features#language-switcher">Global language switch</a></td>
<td><a href="features#character-map"><?= _m_Windows('charmap') ?></a></td>
<td><img class="table-tick" src="<?php echo cdn("img/table-tick.png"); ?>"/></td>
</tr>
<tr>
<td><a href="features#character-map">Character Map tool</a></td>
<td><a href="features#font-helper"><?= _m_Windows('fonthelper') ?></a></td>
<td><img class="table-tick" src="<?php echo cdn("img/table-tick.png"); ?>"/></td>
</tr>
<tr>
<td><a href="features#font-helper">Font helper tool</a></td>
<td><a href="features#character-map"><?= _m_Windows('charident') ?></a></td>
<td><img class="table-tick" src="<?php echo cdn("img/table-tick.png"); ?>"/></td>
</tr>
<tr>
<td><a href="features#character-map">Character Identifier tool</a></td>
<td><?= _m_Windows('hide_startup') ?></td>
<td><img class="table-tick" src="<?php echo cdn("img/table-tick.png"); ?>"/></td>
</tr>
<tr>
<td>Hide startup screen</td>
<td><a href="features#osk"><?= _m_Windows('basic_osk') ?></a></td>
<td><img class="table-tick" src="<?php echo cdn("img/table-tick.png"); ?>"/></td>
</tr>
<tr>
<td><a href="features#osk">Basic On-Screen Keyboard</a></td>
<td><a href="features#osk"><?= _m_Windows('advanced_osk') ?></a></td>
<td><img class="table-tick" src="<?php echo cdn("img/table-tick.png"); ?>"/></td>
</tr>
<tr>
<td><a href="features#osk">Advanced On-Screen Keyboard</a></td>
<td><img class="table-tick" src="<?php echo cdn("img/table-tick.png"); ?>"/></td>
</tr>
<tr>
<th>Technical Support Options</th>
<th><?= _m_Windows('tech_support') ?></th>
<th></th>
</tr>
<tr>
<td><a href="features#support">Web-based Community Technical Support</a></td>
<td><a href="features#support"><?= _m_Windows('web_tech_support') ?></a></td>
<td><img class="table-tick" src="<?php echo cdn("img/table-tick.png"); ?>"/></td>
</tr>
</tbody>
</table>
<p>
You can learn about all the features of Keyman <?= $stable_version; ?> for Windows by <a href="features">clicking here!</a>
<?= _m_Windows('learn_features', $stable_version) ?>
</p>
<div class="button-div">
<a href="download"><img src="<?php echo cdn('img/download_button.png'); ?>" /></a>
</div>
<h2 class="red underline">Frequently Asked Questions</h2>
<p>
<span class="red">Q.</span> Is Keyman really free?
</p>
<p>
<span class="red">A.</span> <a href="../free">Yes</a> it is!
</p>
<br/>
<h2 class="red underline"><?= _m_Windows('faq') ?></h2>
<p>
<span class="red">Q.</span> What versions of Windows will Keyman <?= $stable_version; ?> work with?
<span class="red"><?= _m_Windows('faq_q') ?></span> <?= _m_Windows('faq_free_q') ?>
</p>
<p>
<span class="red">A.</span> Keyman <?= $stable_version; ?> for Windows is compatible with Windows 10, 11, and all later versions. If you're using an older version of Windows, Keyman Desktop 8.0 is still available for download at our archive page <a href="../downloads/archive/">here</a>.
<span class="red"><?= _m_Windows('faq_a') ?></span> <?= _m_Windows('faq_free_a') ?>
</p>
<br/>
<p>
<span class="red">Q.</span> What languages does Keyman support?
<span class="red"><?= _m_Windows('faq_q') ?></span> <?= _m_Windows('faq_windows_q', $stable_version) ?>
</p>
<p>
<span class="red">A.</span> The short answer is a lot! With keyboards for over 2500 languages, there's a very good chance we have yours covered. You can search for a keyboard for your language <a href="/keyboards/">here</a>. If we don't already have a keyboard available, you can use <a href="../developer/">Keyman Developer <?= $stable_version; ?></a> to build one!
<span class="red"><?= _m_Windows('faq_a') ?></span> <?= _m_Windows('faq_windows_a', $stable_version) ?>
</p>
<br/>
<p>
<span class="red">Q.</span> Should I upgrade my older version of Keyman?
<span class="red"><?= _m_Windows('faq_q') ?></span> <?= _m_Windows('faq_languages_q') ?>
</p>
<p>
<span class="red">A.</span> Unless you are using Windows Vista or older version of Windows, we recommend that you upgrade to version <?= $stable_version; ?>.
<span class="red"><?= _m_Windows('faq_a') ?></span> <?= _m_Windows('faq_languages_a', $stable_version) ?>
</p>
<br/>
<p>
<span class="red">Q.</span> Are Keyman Desktop 7.1 and other previous releases still available for download?
<span class="red"><?= _m_Windows('faq_q') ?></span> <?= _m_Windows('faq_upgrade_q') ?>
</p>
<p>
<span class="red">A.</span> Yes, you can find the links to download Keyman Desktop 7.1 and other previous releases <a href="../downloads/archive">here</a>.
<span class="red"><?= _m_Windows('faq_a') ?></span> <?= _m_Windows('faq_upgrade_a', $stable_version) ?>
</p>
<br/>
11 changes: 11 additions & 0 deletions _includes/locale/Locale.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@

Session::Start();

$LOCALE_DEBUG = isset($_REQUEST['LOCALE_DEBUG']);

function define_display_locales() {
$_defined_locales = json_decode(file_get_contents(__DIR__ . '/locales.json'), true);
define('DISPLAY_NAMES', $_defined_locales);
Expand Down Expand Up @@ -339,6 +341,15 @@ private static function getString($domain, $id) {
* @param $args - optional remaining args to the format string
*/
public static function m($domain, $id, ...$args) {
global $LOCALE_DEBUG;
if($LOCALE_DEBUG) {
$result = "◀️$id";
foreach($args as $arg) {
$result .= "{"."$arg}";
}
$result .= "▶️";
return $result;
}
$str = self::getString($domain, $id);
if (count($args) == 0) {
return $str;
Expand Down
101 changes: 101 additions & 0 deletions _includes/locale/strings/windows/en.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,101 @@
<?php

/*
* Keyman is copyright (C) SIL Global. MIT License.
*
* Default English strings for windows/*.php
* When exporting strings from crowdin, convert \\$s to \$s
*/

declare(strict_types=1);

return [
# Page Title {version}
"page_title" => "Keyman for Windows %1\$s",

# Page Description
"page_description" => "Keyman for Windows",

# Page banner title
"page_banner_title" => "Keyman %1\$s for Windows",

# Page banner subtext
"page_banner_subtext" => "Type in your language",

# Introductory heading {version}
"intro_heading" => "Introducing Keyman %1\$s for Windows",

# Introductory paragraphs, HTML {version}
"intro_paras" =>
"<p>
With keyboards for over 2500 languages, Keyman for Windows lets you type in your language even when Windows doesn't.
You can even create your own custom keyboards with <a href='../developer/'>Keyman Developer %1\$s</a>.
</p>
<p>
Our unique virtual keyboard technology makes it easy to type in all your programs, including Microsoft Office,
Adobe Creative Suite, internet browsers and more, as well as supporting the latest version of Windows.
</p>
<p>
With over 30 years of development history, Keyman %1\$s for Windows is the easiest and most efficient version to
use that we've ever built. And now that Keyman is free, we've completely removed any obstacles from getting you
typing right away.
</p>",

# See the features link
"see_the_features" => "See the features",

# Clever Keyboards link
"clever_keyboards" => "Clever keyboards",

# Try the beta version (HTML)
"try_beta" => "Want to try the Keyman for Windows %1\$s Beta? <a href='../beta/'>Learn more</a>",

# Features heading
"features_heading" => "Features",

# "Keyman is Free"
"keyman_is_free" => "Keyman is free and open source.",

# Feature column heading
"feature_column" => "Feature",

"world_leading_im" => "World-leading input methods for thousands of languages",
"create_custom_keyboards" => "Create your own custom keyboards",
"start_with_windows_login" => "Start on Windows Login option",
"number_of_keyboards_install" => "Number of keyboards you can install",
"keyboards_unlimited" => "Unlimited",
"associate_keyboards" => "Associate keyboards with multiple languages",
"advanced_keyboard_info" => "Advanced keyboard information",
"keyboard_hotkeys" => "Keyboard hotkeys",
"interface_hotkeys" => "Interface hotkeys",
"language_switcher" => "Language switcher",
"charmap" => "Character Map tool",
"fonthelper" => "Font helper tool",
"charident" => "Character Identifier tool",
"hide_startup" => "Hide startup screen",
"basic_osk" => "Basic On-Screen Keyboard",
"advanced_osk" => "Advanced On-Screen Keyboard",
"tech_support" => "Technical Support Options",
"web_tech_support" => "Web-based Community Technical Support",
"learn_features" => "You can learn about all the features of Keyman %1\$s for Windows by <a href='features'>clicking here!</a>",

"faq" => "Frequently Asked Questions",
"faq_q" => "Q.",
"faq_a" => "A.",

"faq_free_q" => "Is Keyman really free?",
"faq_free_a" => "<a href='../free'>Yes</a> it is!",

"faq_windows_q" => "What versions of Windows will Keyman %1\$s work with?",
"faq_windows_a" => "Keyman %1\$s for Windows is compatible with Windows 10, 11, and all later versions.
If you're using an older version of Windows, earlier versions of Keyman are still available for
download at our archive page <a href='../downloads/archive/'>here</a>.",

"faq_languages_q" => "What languages does Keyman support?",
"faq_languages_a" => "The short answer is a lot! With keyboards for over 2500 languages, there's a very good chance we
have yours covered. You can search for a keyboard for your language <a href='/keyboards/'>here</a>. If we don't already have a
keyboard available, you can use <a href='../developer/'>Keyman Developer %1\$s</a> to build one!",

"faq_upgrade_q" => "Should I upgrade my older version of Keyman?",
"faq_upgrade_a" => "Unless you are using Windows 8.1 or older version of Windows, we recommend that you upgrade to version %1\$s."
];
Loading