1.1 --- a/css/event-aggregator-print.css Fri Apr 15 00:14:04 2011 +0200
1.2 +++ b/css/event-aggregator-print.css Mon Apr 18 01:06:30 2011 +0200
1.3 @@ -13,8 +13,8 @@
1.4
1.5 /* Controls. */
1.6
1.7 -.previous-month,
1.8 -.next-month,
1.9 +.previous,
1.10 +.next,
1.11 .event-controls {
1.12 display: none;
1.13 }
1.14 @@ -60,5 +60,63 @@
1.15 font-weight: bolder;
1.16 }
1.17
1.18 +/* Map content. */
1.19 +
1.20 +.event-map-container > ol {
1.21 + list-style-type: decimal !important;
1.22 + counter-reset: marker 0;
1.23 +}
1.24 +
1.25 +.event-map-container > img {
1.26 + float: left;
1.27 +}
1.28 +
1.29 +.event-map-container > ol > li {
1.30 + counter-increment: marker;
1.31 + float: left;
1.32 + margin: 0.5em;
1.33 + list-style-position: inside;
1.34 +}
1.35 +
1.36 +.event-map-container > ol > li:before {
1.37 + vertical-align: top;
1.38 +}
1.39 +
1.40 +.event-map-container div.event-map-label-only:before {
1.41 + content: counter(marker);
1.42 +}
1.43 +
1.44 +div.event-map-label-only {
1.45 + display: block;
1.46 + position: absolute;
1.47 + /* position and dimensions specified in the HTML */
1.48 + border: 2px solid #d00;
1.49 +}
1.50 +
1.51 +div.event-map-label {
1.52 + position: static !important;
1.53 + visibility: hidden;
1.54 + display: inline-block;
1.55 + vertical-align: top;
1.56 +}
1.57 +
1.58 +div.event-map-label .event-map-details {
1.59 + position: static !important;
1.60 + display: block;
1.61 + visibility: visible;
1.62 + margin: 0.5em;
1.63 + padding: 0.5em;
1.64 + border: 1px solid #ddd;
1.65 +}
1.66 +
1.67 +.event-map-shadow {
1.68 + visibility: hidden;
1.69 +}
1.70 +
1.71 +.event-map-description {
1.72 + visibility: visible;
1.73 + background-color: transparent;
1.74 +}
1.75 +
1.76 /* vim: tabstop=4 expandtab shiftwidth=4
1.77 */
2.1 --- a/css/event-aggregator.css Fri Apr 15 00:14:04 2011 +0200
2.2 +++ b/css/event-aggregator.css Mon Apr 18 01:06:30 2011 +0200
2.3 @@ -311,6 +311,8 @@
2.4 .event-location-heading {
2.5 text-align: center;
2.6 border: 0;
2.7 + border-left: 1px dotted #ddd;
2.8 + border-right: 1px dotted #ddd;
2.9 background-color: #ffffff;
2.10 }
2.11
2.12 @@ -392,22 +394,37 @@
2.13
2.14 .event-map-container {
2.15 position: relative;
2.16 + margin: 0;
2.17 + padding: 0;
2.18 + text-align: left;
2.19 +}
2.20 +
2.21 +.event-map-container > img {
2.22 + margin: 0;
2.23 + padding: 0;
2.24 + border: 0;
2.25 /* image and dimensions specified in the HTML */
2.26 }
2.27
2.28 +.event-map-container > ol {
2.29 + margin: 0;
2.30 + padding: 0;
2.31 + list-style-type: none;
2.32 +}
2.33 +
2.34 /* Label element and pop-up effects. */
2.35
2.36 -.event-map-label {
2.37 +div.event-map-label-only {
2.38 + display: none;
2.39 +}
2.40 +
2.41 +div.event-map-label {
2.42 position: absolute;
2.43 /* position and dimensions specified in the HTML */
2.44 border: 2px solid #d00;
2.45 }
2.46
2.47 -.event-map-label:hover {
2.48 - border: 0;
2.49 -}
2.50 -
2.51 -.event-map-label .event-map-details {
2.52 +div.event-map-label .event-map-details {
2.53 display: none;
2.54 position: absolute;
2.55 top: 0;
2.56 @@ -416,7 +433,7 @@
2.57 min-width: 10em;
2.58 }
2.59
2.60 -.event-map-label:hover .event-map-details {
2.61 +div.event-map-label:hover .event-map-details {
2.62 display: block;
2.63 }
2.64
2.65 @@ -437,6 +454,7 @@
2.66 .event-map-description p {
2.67 font-weight: bold;
2.68 font-size: larger;
2.69 + text-align: center;
2.70 }
2.71
2.72 ul.event-map-description-events {
3.1 --- a/macros/EventAggregator.py Fri Apr 15 00:14:04 2011 +0200
3.2 +++ b/macros/EventAggregator.py Mon Apr 18 01:06:30 2011 +0200
3.3 @@ -1517,10 +1517,9 @@
3.4 output.append(fmt.table_row(on=1))
3.5 output.append(fmt.table_cell(on=1))
3.6
3.7 - output.append(fmt.div(on=1, css_class="event-map-container",
3.8 - style="width: %spx; height: %spx; background-image: url('%s')" % (
3.9 - escattr(map_width), escattr(map_height), map_image_url)
3.10 - ))
3.11 + output.append(fmt.div(on=1, css_class="event-map-container"))
3.12 + output.append(fmt.image(map_image_url))
3.13 + output.append(fmt.number_list(on=1))
3.14
3.15 # Show the events in the map.
3.16
3.17 @@ -1549,14 +1548,26 @@
3.18 # NOTE: Use one degree as the marker size.
3.19
3.20 marker_x, marker_y = getPositionForCentrePoint(
3.21 - getPositionForReference(latitude, longitude, map_bottom_left_latitude, map_bottom_left_longitude,
3.22 + getPositionForReference(map_top_right_latitude, longitude, latitude, map_bottom_left_longitude,
3.23 map_x_scale, map_y_scale),
3.24 map_x_scale, map_y_scale)
3.25
3.26 # Put a marker on the map.
3.27
3.28 + output.append(fmt.listitem(on=1, css_class="event-map-label"))
3.29 +
3.30 + # Have a positioned marker for the print mode.
3.31 +
3.32 + output.append(fmt.div(on=1, css_class="event-map-label-only",
3.33 + style="left:%dpx; top:%dpx; min-width:%dpx; min-height:%dpx") % (
3.34 + marker_x, marker_y, map_x_scale, map_y_scale))
3.35 + output.append(fmt.div(on=0))
3.36 +
3.37 + # Have a marker containing a pop-up when using the screen mode,
3.38 + # providing a normal block when using the print mode.
3.39 +
3.40 output.append(fmt.div(on=1, css_class="event-map-label",
3.41 - style="left:%dpx; bottom:%dpx; min-width:%dpx; min-height:%dpx") % (
3.42 + style="left:%dpx; top:%dpx; min-width:%dpx; min-height:%dpx") % (
3.43 marker_x, marker_y, map_x_scale, map_y_scale))
3.44 output.append(fmt.div(on=1, css_class="event-map-details"))
3.45 output.append(fmt.div(on=1, css_class="event-map-shadow"))
3.46 @@ -1584,9 +1595,11 @@
3.47 output.append(fmt.div(on=0))
3.48 output.append(fmt.div(on=0))
3.49 output.append(fmt.div(on=0))
3.50 + output.append(fmt.listitem(on=0))
3.51
3.52 # End of map view output.
3.53
3.54 + output.append(fmt.number_list(on=0))
3.55 output.append(fmt.div(on=0))
3.56 output.append(fmt.table_cell(on=0))
3.57 output.append(fmt.table_row(on=0))