Index: trunk/calendar/inc/class.uicalendar.inc.php
===================================================================
--- trunk/calendar/inc/class.uicalendar.inc.php	(revision 4565)
+++ trunk/calendar/inc/class.uicalendar.inc.php	(revision 4705)
@@ -5165,5 +5165,5 @@
 			)
 		    );
-
+                    $this->bo->read_holidays($params['year']);
 		    $next = $GLOBALS['phpgw']->datetime->makegmttime(0,0,0,$this->bo->month,$this->bo->day + 7,$this->bo->year);
 		    $prev = $GLOBALS['phpgw']->datetime->makegmttime(0,0,0,$this->bo->month,$this->bo->day - 7,$this->bo->year);
@@ -5188,5 +5188,9 @@
 			'new_week'   => $tpl,
 		    );
-
+                    $feriados_do_ano = Array();
+                    foreach ($this->bo->cached_holidays as $key => $value)
+                        {
+                            $feriados_do_ano[$key] = utf8_encode($this->bo->cached_holidays[$key][0]['name']);
+                        }
 		    $p->set_file($templates);
 		    $p->set_block('new_week','day','day');
@@ -5202,4 +5206,5 @@
                     $p->set_var('user',$GLOBALS['phpgw']->common->grab_owner_name($this->bo->owner));
 		    $p->set_var('events_json',json_encode($result_events_json['events_to_show_json'])?json_encode($result_events_json['events_to_show_json']):'null');
+                    $p->set_var('holidays_json',json_encode($feriados_do_ano)?json_encode($feriados_do_ano):null);
 		    return $p->fp('out','day');
 
@@ -5210,5 +5215,4 @@
 			$p = CreateObject('phpgwapi.Template',$this->template_dir);
 			$p->set_unknowns('keep');
-
 			$tpl = 'new_month.tpl';
 
@@ -5257,5 +5261,5 @@
 					)
 				);
-
+                        $this->bo->read_holidays($params['year']);
 			$print =  '<a href="javascript:void(0)" id="printFriendly">['.lang('Printer Friendly').']</a>';
 
@@ -5277,4 +5281,9 @@
 			}
 
+                        $feriados_do_ano = Array();
+                        foreach ($this->bo->cached_holidays as $key => $value)
+                        {
+                            $feriados_do_ano[$key] = utf8_encode($this->bo->cached_holidays[$key][0]['name']);
+                        }
                         $m = mktime(0,0,0,$this->bo->month,1,$this->bo->year);
 			$p->set_file($templates);
@@ -5293,4 +5302,5 @@
                         $p->set_var('user',$GLOBALS['phpgw']->common->grab_owner_name($this->bo->owner));
 			$p->set_var('events_json',json_encode($result_events_json['events_to_show_json'])?json_encode($result_events_json['events_to_show_json']):'null');
+                        $p->set_var('holidays_json',json_encode($feriados_do_ano)?json_encode($feriados_do_ano):null);
                         return $p->fp('out','day');
                 }
Index: trunk/calendar/js/dhtmlx/sources/ext/ext_new_month.js
===================================================================
--- trunk/calendar/js/dhtmlx/sources/ext/ext_new_month.js	(revision 4705)
+++ trunk/calendar/js/dhtmlx/sources/ext/ext_new_month.js	(revision 4705)
@@ -0,0 +1,69 @@
+scheduler._reset_month_scale=function(b,dd,sd){
+	var ed=scheduler.date.add(dd,1,"month");
+
+	//trim time part for comparation reasons
+	var cd=new Date();
+	this.date.date_part(cd);
+	this.date.date_part(sd);
+
+	var rows=Math.ceil((ed.valueOf()-sd.valueOf())/(60*60*24*1000*7));
+	var tdcss=[];
+	var height=(Math.floor(b.clientHeight/rows)-22);
+
+	this._colsS.height=height+22;
+	var h = this._colsS.heights = [];
+	for (var i=0; i<=7; i++)
+		tdcss[i]=" style='height:"+height+"px; width:"+((this._cols[i]||0)-1)+"px;' "
+
+var cellheight = 0;
+	this._min_date=sd;
+	var html="<table cellpadding='0' cellspacing='0'>";
+	for (var i=0; i<rows; i++){
+		html+="<tr>";
+			for (var j=0; j<7; j++){
+				html+="<td";
+				var cls = "";
+                                var clstitle = "";
+                                var aaaa = sd.getFullYear();
+                                var mm = sd.getMonth()+1;
+                                var dd = sd.getDate();
+                                aaaa = aaaa.toString();
+                                mm = mm.toString();
+                                dd = dd.toString();
+                                if(mm.length < 2) mm = '0' + mm;
+                                if(dd.length < 2) dd = '0' + dd;
+                                var aaaammdd = aaaa + mm + dd;
+				if (holidayTab[aaaammdd])
+				{
+					cls = 'dhx_holiday';
+                                        clstitle = holidayTab[aaaammdd];
+				}
+
+				if (sd<dd)
+					cls='dhx_before';
+				else if (sd>=ed)
+					cls='dhx_after';
+				else if (sd.valueOf()==cd.valueOf())
+					cls='dhx_now';
+
+				if (sd.valueOf()==cd.valueOf() && holidayTab[aaaammdd])
+				{
+					cls = 'dhx_now_holiday';
+                                        clstitle = holidayTab[aaaammdd];
+				}
+
+
+				html+=" class='"+cls+" "+this.templates.month_date_class(sd,cd)+"' ";
+				html+="><div class='dhx_month_head' title='" + clstitle + "'>"+this.templates.month_day(sd)+"</div><div class='dhx_month_body' "+tdcss[j]+"></div></td>"
+				sd=this.date.add(sd,1,"day");
+			}
+		html+="</tr>";
+		h[i] = cellheight;
+		cellheight+=this._colsS.height;
+	}
+	html+="</table>";
+	this._max_date=sd;
+
+	b.innerHTML=html;
+	return sd;
+}
Index: trunk/calendar/js/dhtmlx/sources/ext/ext_new_week.js
===================================================================
--- trunk/calendar/js/dhtmlx/sources/ext/ext_new_week.js	(revision 4098)
+++ trunk/calendar/js/dhtmlx/sources/ext/ext_new_week.js	(revision 4705)
@@ -120,8 +120,30 @@
 				html+="<td";
 				var cls = "";
+                                var clstitle = "";
 				if (sd.valueOf()==cd.valueOf())
 					cls='dhx_now';
+                                var aaaa = sd.getFullYear();
+                                var mm = sd.getMonth()+1;
+                                var dd = sd.getDate();
+                                aaaa = aaaa.toString();
+                                mm = mm.toString();
+                                dd = dd.toString();
+                                if(mm.length < 2) mm = '0' + mm;
+                                if(dd.length < 2) dd = '0' + dd;
+                                var aaaammdd = aaaa + mm + dd;
+				if (holidayTab[aaaammdd])
+				{
+					cls = 'dhx_holiday';
+                                        clstitle = holidayTab[aaaammdd];
+				}
+
+				if (sd.valueOf()==cd.valueOf() && holidayTab[aaaammdd])
+				{
+					cls = 'dhx_now_holiday';
+                                        clstitle = holidayTab[aaaammdd];
+				}
+
 				html+=" class='"+cls+" "+this.templates.month_date_class(sd,cd)+"' ";
-				html+="><div class='dhx_month_head'>"+this.templates.week_scale_date(sd)+"</div><div class='dhx_month_body' "+tdcss[j]+"></div></td>"
+				html+="><div class='dhx_month_head' title='" + clstitle + "'> "+this.templates.week_scale_date(sd)+"</div><div class='dhx_month_body' "+tdcss[j]+"></div></td>"
 				sd=this.date.add(sd,1,"day");
                                 if(i==3)
Index: trunk/calendar/js/dhtmlx/codebase/dhtmlxscheduler.css
===================================================================
--- trunk/calendar/js/dhtmlx/codebase/dhtmlxscheduler.css	(revision 4001)
+++ trunk/calendar/js/dhtmlx/codebase/dhtmlxscheduler.css	(revision 4705)
@@ -11,2 +11,9 @@
 
     }
+
+    .dhx_holiday .dhx_month_head{background-color:#c68686;}
+    .dhx_holiday .dhx_month_body{background-color:#dab0b0;}
+
+    .dhx_now_holiday .dhx_month_head{background-color:#c68686;}
+    .dhx_now_holiday .dhx_month_body{background-color:#E2EDFF;}
+    
Index: trunk/calendar/templates/default/new_month.tpl
===================================================================
--- trunk/calendar/templates/default/new_month.tpl	(revision 4125)
+++ trunk/calendar/templates/default/new_month.tpl	(revision 4705)
@@ -5,4 +5,5 @@
 <script src="calendar/js/dhtmlx/sources/ext/ext_pdf.js"></script>
 <script src="calendar/js/dhtmlx/sources/locale_pt.js"></script>
+<script src="calendar/js/dhtmlx/sources/ext/ext_new_month.js"></script>
 <script>
 
@@ -68,5 +69,5 @@
 
 <script>
-
+    var holidayTab = {holidays_json};
     function printMode(printType)
     {
@@ -150,4 +151,6 @@
 	scheduler.parse({events_json},"json");
 
+
+
     }
 
Index: trunk/calendar/templates/default/new_week.tpl
===================================================================
--- trunk/calendar/templates/default/new_week.tpl	(revision 4125)
+++ trunk/calendar/templates/default/new_week.tpl	(revision 4705)
@@ -7,5 +7,5 @@
 <script src="calendar/js/dhtmlx/sources/ext/ext_new_week.js"></script>
 <script>
-
+    var holidayTab = {holidays_json};
     resize = function(){
 
