Index: /CKEditor/trunk/CHANGES.html
===================================================================
--- /CKEditor/trunk/CHANGES.html	(revision 6138)
+++ /CKEditor/trunk/CHANGES.html	(revision 6139)
@@ -64,4 +64,5 @@
 		<li><a href="http://dev.ckeditor.com/ticket/6580">#6580</a> : [IE9] Flash dialog doesn't get filled up.</li>
 		<li><a href="http://dev.ckeditor.com/ticket/6447">#6447</a> : Outdent list with "indentClasses" config doesn't work.</li>
+		<li><a href="http://dev.ckeditor.com/ticket/5894">#5894</a> : Custom buttons added at bottom of dialogs don't expand to include their contents.</li>
 	</ul>
 	<h3>
Index: /CKEditor/trunk/_source/skins/kama/dialog.css
===================================================================
--- /CKEditor/trunk/_source/skins/kama/dialog.css	(revision 6138)
+++ /CKEditor/trunk/_source/skins/kama/dialog.css	(revision 6139)
@@ -395,4 +395,5 @@
 .cke_skin_kama a.cke_dialog_ui_button_cancel span
 {
+	width:60px;
 	padding-right: 20px;
 	padding-left: 20px;
@@ -518,5 +519,4 @@
 {
 	margin: 7px 0;
-	width: 60px;
 	text-align: center;
 }
Index: /CKEditor/trunk/_source/skins/office2003/dialog.css
===================================================================
--- /CKEditor/trunk/_source/skins/office2003/dialog.css	(revision 6138)
+++ /CKEditor/trunk/_source/skins/office2003/dialog.css	(revision 6139)
@@ -430,4 +430,10 @@
 }
 
+.cke_skin_office2003 a.cke_dialog_ui_button_ok span,
+.cke_skin_office2003 a.cke_dialog_ui_button_cancel span
+{
+	width:60px;
+}
+
 .cke_skin_office2003 span.cke_dialog_ui_button
 {
@@ -486,5 +492,4 @@
 .cke_skin_office2003 .cke_dialog_footer_buttons span.cke_dialog_ui_button
 {
-	width: 60px;
 	margin: 7px 0;
 }
Index: /CKEditor/trunk/_source/skins/v2/dialog.css
===================================================================
--- /CKEditor/trunk/_source/skins/v2/dialog.css	(revision 6138)
+++ /CKEditor/trunk/_source/skins/v2/dialog.css	(revision 6139)
@@ -429,4 +429,10 @@
 }
 
+.cke_skin_v2 a.cke_dialog_ui_button_ok span,
+.cke_skin_v2 a.cke_dialog_ui_button_cancel span
+{
+	width:60px;
+}
+
 .cke_skin_v2 span.cke_dialog_ui_button
 {
@@ -482,5 +488,4 @@
 .cke_skin_v2 .cke_dialog_footer_buttons span.cke_dialog_ui_button
 {
-	width: 60px;
 	margin: 7px 0;
 }
Index: /CKEditor/trunk/_source/themes/default/theme.js
===================================================================
--- /CKEditor/trunk/_source/themes/default/theme.js	(revision 6138)
+++ /CKEditor/trunk/_source/themes/default/theme.js	(revision 6139)
@@ -185,8 +185,12 @@
 								'<a id="%close_button#" class="%close_button" href="javascript:void(0)" title="' +  editor.lang.common.close+'" role="button"><span class="cke_label">X</span></a>' +
 								'<div id="%tabs#" class="%tabs" role="tablist"></div>' +
-								'<table class="%contents" role="presentation"><tr>' +
+								'<table class="%contents" role="presentation">' +
+								'<tr>' +
 								  '<td id="%contents#" class="%contents" role="presentation"></td>' +
-								'</tr></table>' +
-								'<div id="%footer#" class="%footer" role="presentation"></div>' +
+								'</tr>' +
+								'<tr>' +
+								  '<td id="%footer#" class="%footer" role="presentation"></td>' +
+								'</tr>' +
+								'</table>' +
 							'</div>' +
 							'<div id="%tl#" class="%tl"></div>' +
@@ -227,5 +231,5 @@
 					tabs		: body.getChild( 2 ),
 					contents	: body.getChild( [ 3, 0, 0, 0 ] ),
-					footer		: body.getChild( 4 )
+					footer		: body.getChild( [ 3, 0, 1, 0 ] )
 				}
 			};
