aboutsummaryrefslogtreecommitdiffhomepage
path: root/index.php
diff options
context:
space:
mode:
Diffstat (limited to 'index.php')
-rw-r--r--index.php5
1 files changed, 3 insertions, 2 deletions
diff --git a/index.php b/index.php
index 474d9af5..b53b16fe 100644
--- a/index.php
+++ b/index.php
@@ -659,6 +659,7 @@ function renderPage($conf, $pluginManager, $bookmarkService, $history, $sessionM
659 659
660 alphabetical_sort($tags, false, true); 660 alphabetical_sort($tags, false, true);
661 661
662 $logMaxCount = $maxcount > 1 ? log($maxcount, 30) : 1;
662 $tagList = array(); 663 $tagList = array();
663 foreach ($tags as $key => $value) { 664 foreach ($tags as $key => $value) {
664 if (in_array($key, $filteringTags)) { 665 if (in_array($key, $filteringTags)) {
@@ -666,8 +667,8 @@ function renderPage($conf, $pluginManager, $bookmarkService, $history, $sessionM
666 } 667 }
667 // Tag font size scaling: 668 // Tag font size scaling:
668 // default 15 and 30 logarithm bases affect scaling, 669 // default 15 and 30 logarithm bases affect scaling,
669 // 22 and 6 are arbitrary font sizes for max and min sizes. 670 // 2.2 and 0.8 are arbitrary font sizes in em.
670 $size = log($value, 15) / log($maxcount, 30) * 2.2 + 0.8; 671 $size = log($value, 15) / $logMaxCount * 2.2 + 0.8;
671 $tagList[$key] = array( 672 $tagList[$key] = array(
672 'count' => $value, 673 'count' => $value,
673 'size' => number_format($size, 2, '.', ''), 674 'size' => number_format($size, 2, '.', ''),