Author:   Lars Michelsen <[email protected]>
Date:     Mon Jul  1 10:09:46 2013 +0200
Committer:   Lars Michelsen <[email protected]>
Commit-Date: Mon Jul  1 10:09:46 2013 +0200

Improved automap host label handling

---

 ChangeLog                                 |    4 ++++
 share/server/core/sources/automap.php     |    1 +
 share/server/core/sources/automap_pos.php |    2 +-
 3 files changed, 6 insertions(+), 1 deletions(-)

diff --git a/ChangeLog b/ChangeLog
index 51aada7..ddf127c 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -3,6 +3,10 @@ Frontend:
   * Weathermap lines now deal with bit/byte values provided by Check_MKs
     interface checks
 
+Automap:
+  * Labels have now a white background to improve the text readability
+  * Labels should not overlap on automaps with many hosts anymore
+
 1.7.9
 Core:
   * Livestatus: Fixed handling of hosts/services without custom variables
diff --git a/share/server/core/sources/automap.php 
b/share/server/core/sources/automap.php
index 6623a2f..aba8fa0 100644
--- a/share/server/core/sources/automap.php
+++ b/share/server/core/sources/automap.php
@@ -304,6 +304,7 @@ function automap_obj($MAPCFG, &$params, &$saved_config, 
$obj_name) {
 
     $obj['label_show']       = true;
     $obj['label_border']     = 'transparent';
+    $obj['label_background'] = '#fff';
 
     // Header menu has z-index 100, this object's label the below+1
     $obj['z']           = 98;
diff --git a/share/server/core/sources/automap_pos.php 
b/share/server/core/sources/automap_pos.php
index 9958d98..4329286 100644
--- a/share/server/core/sources/automap_pos.php
+++ b/share/server/core/sources/automap_pos.php
@@ -52,7 +52,7 @@ function graphviz_config_tree(&$params, &$tree, $layer = 0) {
     $name = $tree['host_name'];
 
     $str .= '    "'.$tree['object_id'].'" [ ';
-    $str .= 'label="", ';
+    $str .= 'label="'.$tree['host_name'].'", ';
     $str .= 'URL="'.$tree['object_id'].'", ';
     $str .= 'tooltip="'.$tree['object_id'].'", ';
     


------------------------------------------------------------------------------
This SF.net email is sponsored by Windows:

Build for Windows Store.

http://p.sf.net/sfu/windows-dev2dev
_______________________________________________
Nagvis-checkins mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/nagvis-checkins

Reply via email to