summaryrefslogtreecommitdiff
path: root/reportdesign
diff options
context:
space:
mode:
authorKurt Zenker <kz@openoffice.org>2009-06-05 09:47:55 +0000
committerKurt Zenker <kz@openoffice.org>2009-06-05 09:47:55 +0000
commitbda7e683aeb1e4f64967a0cb2bd69c9152c44037 (patch)
treea1e2663822ceabfc04d2cce904ac82fa58c9126e /reportdesign
parentd637b522f06e03ef544c7ee367a25a4956c8bb64 (diff)
CWS-TOOLING: integrate CWS dba32b
2009-06-03 14:58:08 +0200 fs r272581 : #i102439# 2009-05-29 13:56:18 +0200 fs r272456 : remove the sub form when the 'add subform' setting changes from <true/> to <false/>, not only its controls 2009-05-29 13:19:27 +0200 fs r272454 : display '(Default)' instead of an empty string when a control has the default font 2009-05-28 20:49:18 +0200 fs r272428 : #i98162# getFirstSelectedValue: do not return reference to a temporary 2009-05-27 15:30:22 +0200 msc r272353 : #102303# 2009-05-26 13:03:06 +0200 fs r272295 : spelling 2009-05-26 12:59:54 +0200 fs r272294 : merge m48 version to get latest cygwin related fixes 2009-05-25 14:02:06 +0200 fs r272239 : remove references to local files, needed for debugging sessions only 2009-05-25 14:01:16 +0200 fs r272238 : #i102021# ensure members such as bNumberFormat are initialized before actually returning them 2009-05-25 13:10:20 +0200 fs r272236 : #i10000# reset ENABLE_EVOAB2 2009-05-22 06:44:45 +0200 oj r272167 : #i99104# add import handler for calc-sett 2009-05-22 06:42:27 +0200 oj r272166 : #i99104# impl NullDate as member 2009-05-22 06:36:22 +0200 oj r272165 : #i99104# handle nulldate from parent model 2009-05-22 06:33:13 +0200 oj r272164 : #i99104# export and import calculation-settings and nulldate 2009-05-22 06:27:50 +0200 oj r272163 : #i99104# export and import calculation-settings and nulldate 2009-05-20 13:29:58 +0200 oj r272118 : #i99911# handle invalid name 2009-05-20 13:28:49 +0200 oj r272117 : #i101261# handle different rowsets 2009-05-20 11:29:55 +0200 msc r272111 : #i100000# 2009-05-20 11:28:27 +0200 msc r272110 : merge in change from dba32a 2009-05-20 11:27:38 +0200 msc r272109 : #102082# CTRL + C does not work 2009-05-20 09:43:36 +0200 oj r272106 : clean up includes 2009-05-20 09:32:15 +0200 oj r272105 : #i99060# merge error resovled now VERTICAL_ALIGN is in both stmt 2009-05-20 08:37:21 +0200 msc r272104 : add workaround for issue #102010# 2009-05-20 08:10:12 +0200 oj r272103 : #i99104# use numberformatkey 2009-05-20 08:07:02 +0200 oj r272102 : #i99104# use column info from rowset 2009-05-20 08:04:43 +0200 oj r272101 : #i102032# use a special column type where prec and scale are the values currently set at the column 2009-05-20 08:03:04 +0200 oj r272100 : #i102032# correct type info, we have to use SQL defined type names 2009-05-19 10:27:02 +0200 oj r272061 : #i99104# export null-date 2009-05-19 08:26:53 +0200 oj r272056 : #i99104# export null-date 2009-05-18 13:15:10 +0200 msc r272014 : add issue #102019# 2009-05-18 11:33:07 +0200 msc r272005 : add issue #102019# 2009-05-18 08:59:45 +0200 msc r271996 : add workaroud for issue #102010# 2009-05-15 10:21:24 +0200 msc r271929 : #101944# 2009-05-11 21:18:30 +0200 fs r271792 : #i99914# 2009-05-08 13:52:06 +0200 oj r271715 : #i96423# remember column span 2009-05-08 11:26:19 +0200 oj r271708 : #i98605# impl new scale mode 2009-05-08 10:33:35 +0200 fs r271706 : SendUserCall: only call into the shape notification routine for UserCall types where this is necessary (performance issue) 2009-05-07 20:52:44 +0200 fs r271698 : outsource ShapeProperty from shapepropertynotifier.hxx 2009-05-07 20:43:33 +0200 fs r271697 : #i99056# use notifyShapePropertyChange, instead of getShapePropertyChangeNotifier - the latter throws if no shape exists, yet 2009-05-07 20:33:58 +0200 fs r271696 : #i99056# +notifyShapePropertyChange: allow notifying chages without checking whether there actually already exists an SvxShape 2009-05-07 16:22:15 +0200 fs r271679 : #i10000# cygwin needs quotes around the classpath 2009-05-07 16:21:37 +0200 fs r271678 : #i10000# cygwin needs quotes around the classpath 2009-05-07 16:01:11 +0200 oj r271677 : #i99914# notify parent handler 2009-05-07 15:54:54 +0200 fs r271676 : #i10000# cygwin needs some quoting 2009-05-07 14:49:48 +0200 oj r271672 : #i99277# quote alias name 2009-05-07 14:48:12 +0200 oj r271671 : #i92538# add ~ in front of type 2009-05-07 14:37:13 +0200 oj r271667 : #i99118# change type from char to varchar 2009-05-07 14:36:23 +0200 oj r271666 : #i99118# clear dest columns when changing to create new table 2009-05-07 13:35:32 +0200 oj r271657 : #i94467# handle type 0 as double as well 2009-05-07 13:20:49 +0200 oj r271655 : i99743# setNull when varchar is no text 2009-05-07 12:58:06 +0200 fs r271651 : initialize the SdrObject's property change notifier after the ctor, if necessary 2009-05-07 11:47:18 +0200 fs r271647 : #i10000# 2009-05-07 10:57:16 +0200 fs r271639 : OPropertyBrowserController::propertyChange: care for the current property state, too, and properly forward it to the UI 2009-05-07 10:18:14 +0200 fs r271636 : onNewComponent: do not ask the map for grid columns, it will throw 2009-05-07 10:09:55 +0200 fs r271634 : #i101623# 2009-05-07 09:53:44 +0200 fs r271631 : #i101622# 2009-05-06 21:55:53 +0200 fs r271615 : #i10000# 2009-05-06 21:10:42 +0200 fs r271611 : #i10000# 2009-05-06 13:11:48 +0200 fs r271583 : #i10000# 2009-05-05 22:29:31 +0200 fs r271559 : proper assertion message 2009-05-05 22:29:03 +0200 fs r271558 : diagnostics 2009-05-05 22:16:16 +0200 fs r271557 : #i10000# 2009-05-05 13:50:32 +0200 fs r271513 : #i10000# 2009-05-05 10:21:50 +0200 fs r271503 : #i10000# 2009-05-05 09:30:26 +0200 fs r271501 : why did those survive the rebase -C step? 2009-05-05 09:18:12 +0200 fs r271500 : #i10000# 2009-05-04 17:08:17 +0200 fs r271475 : CWS-TOOLING: rebase CWS dba32b to trunk@271427 (milestone: DEV300:m47) 2009-05-04 14:51:26 +0200 fs r271456 : line ends 2009-04-30 15:55:27 +0200 fs r271418 : NewURL -> PublicConnectionURL 2009-04-22 21:18:34 +0200 fs r271141 : #i100944# 2009-04-22 09:12:26 +0200 oj r271071 : #i101261# little code change 2009-04-22 09:11:43 +0200 oj r271070 : #i101261# only ask for parameters which aren't set before 2009-04-22 09:11:25 +0200 oj r271069 : #i101261# new grabage container for nodes 2009-04-22 09:11:02 +0200 oj r271068 : #i101261# new grabage container for nodes 2009-04-22 09:10:44 +0200 oj r271067 : #i101261# new grabage container for nodes 2009-04-22 09:10:21 +0200 oj r271066 : #i101261# only ask for parameters which aren't set before 2009-04-22 09:08:24 +0200 oj r271065 : #i101261# only ask for parameters which aren't set before 2009-04-22 09:07:25 +0200 oj r271064 : #i101261# only ask for parameters which aren't set before 2009-04-22 08:49:07 +0200 oj r271062 : #i77501# preview only when needed 2009-04-22 08:45:44 +0200 oj r271061 : #i101261# new prop max rows 2009-04-22 08:44:18 +0200 oj r271060 : #i101261# create dataprovider earlier to avoid the wrong legend in chart 2009-04-22 08:42:48 +0200 oj r271059 : #i101261# handle parameter 2009-04-17 21:00:23 +0200 fs r270954 : #i98350# 2009-04-17 13:54:19 +0200 fs r270942 : #i99565# 2009-04-17 13:51:34 +0200 fs r270940 : #i101153# only localize the (potentially) localizable properties when there really is support at the control model 2009-04-17 11:43:14 +0200 fs r270932 : removed superfluous include 2009-04-17 10:10:15 +0200 fs r270926 : #i10000# 2009-04-17 10:02:36 +0200 fs r270925 : #i10000# 2009-04-17 09:15:13 +0200 fs r270918 : #i99056# some more refactoring of the recently introduced property change notification mechanism for UNO shapes 2009-04-17 09:14:56 +0200 fs r270917 : #i99056# some more refactoring of the recently introduced property change notification mechanism for UNO shapes 2009-04-17 09:13:25 +0200 fs r270915 : #i99056# some more refactoring of the recently introduced property change notification mechanism for UNO shapes 2009-04-17 08:30:34 +0200 fs r270914 : removed unotools/servicehelper.hxx in favour of the (duplicated) comphelper/servicehelper.hxx 2009-04-16 21:05:25 +0200 fs r270903 : #i10000# 2009-04-16 20:43:43 +0200 fs r270902 : #i99056# shape notification outsourced to the SdrObject, this is what all other shape implementations (which only aggregate an SvxShape) have access to, too 2009-04-16 15:57:36 +0200 fs r270891 : #i99056# make SetUnoControlModel virtual 2009-04-16 15:44:02 +0200 fs r270890 : #i99056# let the ScShapeObj notify changes in its Anchor property 2009-04-16 15:36:47 +0200 fs r270889 : #i99056# enable the sheet anchor type property, too 2009-04-16 15:33:45 +0200 fs r270887 : #i99056# shape notification outsourced to the SdrObject, this is what all other shape implementations (which only aggregate an SvxShape) have access to, too 2009-04-15 14:53:13 +0200 fs r270844 : #i10000# 2009-04-15 13:08:29 +0200 fs r270836 : #i10000# 2009-04-15 12:28:14 +0200 fs r270832 : #i10000# 2009-04-15 10:59:14 +0200 fs r270827 : #i10000# 2009-04-15 09:41:08 +0200 oj r270823 : fix issues found with findbugs and pmd 2009-04-14 21:08:04 +0200 fs r270808 : #i99056# implement SheetAnchorType - now the only thing missing to enable it is the proper notification when it is modified 2009-04-14 17:09:00 +0200 fs r270799 : #i99056# implement XServiceInfo for the ScShapeObj 2009-04-14 17:07:55 +0200 fs r270798 : #i99056# implement TextAnchorType, partially implement SheetAnchorType 2009-04-14 15:54:05 +0200 fs r270786 : #i99056# SwXShape: notify changes of the AnchorType property 2009-04-14 15:47:32 +0200 fs r270785 : #i99056# deliver shapepropertynotifier.hxx 2009-04-14 15:46:54 +0200 fs r270784 : diagnostics 2009-04-14 15:08:28 +0200 fs r270781 : #i99056# outsourced the SvxShape's property change notification code into a dedicated class 2009-04-14 14:41:09 +0200 fs r270773 : #i99056# outsourced the SvxShape's property change notification code into a dedicated class 2009-04-14 14:37:23 +0200 fs r270772 : in dtor, remove the properties from the temporary component context 2009-04-14 14:36:34 +0200 fs r270771 : getWeakUnoShape made const 2009-04-14 12:23:08 +0200 oj r270757 : #i101064# add missing braces 2009-04-14 12:21:25 +0200 oj r270756 : #i101065# add braces for gcc 4.3.2 2009-04-14 12:17:45 +0200 oj r270755 : #i101059# add dep for manifest 2009-04-09 12:06:58 +0200 oj r270686 : #i93100# use OptimalSize from control to get height 2009-04-08 09:56:55 +0200 oj r270619 : #i92537# handle calculations in the select columns as well 2009-04-08 09:30:39 +0200 oj r270615 : #i96657# throw error message when the key doesn't have any columns 2009-04-07 12:08:26 +0200 oj r270592 : #i77501# impl preview of the executed report 2009-04-07 12:01:56 +0200 oj r270591 : #i77501# impl preview of the executed report 2009-04-07 11:41:03 +0200 oj r270590 : #i77501# impl preview of the executed report 2009-04-07 11:39:32 +0200 oj r270589 : #i77501# impl preview of the executed report 2009-04-07 11:29:25 +0200 oj r270588 : #i77501# convert dos to unix lineends 2009-04-07 11:28:23 +0200 oj r270587 : #i77501# impl preview of the executed report 2009-04-07 11:16:50 +0200 oj r270586 : #i77501# impl preview of the executed report 2009-04-07 11:16:00 +0200 oj r270585 : #i77501# impl preview of the executed report 2009-04-07 11:15:44 +0200 oj r270584 : #i77501# impl preview of the executed report 2009-04-07 11:15:28 +0200 oj r270583 : #i77501# impl preview of the executed report 2009-04-07 11:15:04 +0200 oj r270582 : #i77501# impl preview of the executed report 2009-04-06 15:38:54 +0200 fs r270559 : merge changes from CWS dba32a herein 2009-04-03 15:56:16 +0200 fs r270494 : ImpSvMEdit::Resize: do multiple iterations, if necessary 2009-04-03 14:35:49 +0200 fs r270487 : #i10000# 2009-04-03 13:17:16 +0200 fs r270476 : #i99056# display geometry information for controls, too 2009-04-03 13:16:37 +0200 fs r270475 : #i99056# better ordering of the geometry properties 2009-04-03 13:16:07 +0200 fs r270473 : #i99056# now that SvxShape supports property change listeners, forward add/remove requests to it 2009-04-03 13:13:18 +0200 fs r270472 : #i99056# at SvxShape, allow for PropertyChangeListeners for Size/Position 2009-04-03 09:29:27 +0200 oj r270456 : #i94571# use correct prop name 2009-04-03 09:14:54 +0200 fs r270451 : merge changes from CWS dba32a herein 2009-04-02 17:00:51 +0200 fs r270424 : better diagnostics 2009-04-02 16:35:19 +0200 fs r270421 : diagnostics 2009-04-02 16:34:50 +0200 fs r270420 : #i99056# mxUnoShape not accessible anymore, use impl_setUnoShape instead 2009-04-02 16:32:48 +0200 fs r270419 : #i99056# make getUnoShape cheaper: keep the pointer to the SvxShape all the time, so there's no need to ask for it in getUnoShape. As a consequence, we will later be able to use the pointer in scenarious where performance (potentially) matters 2009-04-02 16:31:13 +0200 fs r270417 : merge changes from CWS dba32a herein 2009-04-02 16:23:16 +0200 fs r270414 : merge changes from CWS dba32a herein 2009-04-02 14:10:35 +0200 fs r270405 : #i10000# 2009-04-02 14:06:26 +0200 fs r270404 : merge changes from CWS dba32a herein 2009-04-02 14:03:03 +0200 fs r270401 : #i10000# 2009-04-02 13:58:13 +0200 fs r270400 : #i10000# 2009-04-02 12:59:44 +0200 fs r270397 : merge changes from CWS dba32a herein 2009-04-02 12:46:30 +0200 fs r270396 : #i99056# let the form page maintain a mapping between control models and control shapes 2009-04-02 12:44:07 +0200 fs r270395 : merge changes from CWS dba32a herein 2009-04-02 12:42:06 +0200 fs r270394 : merge changes from CWS dba32a herein 2009-04-02 12:35:20 +0200 fs r270393 : #i10000# precompiled header 2009-04-02 12:05:31 +0200 fs r270392 : merge changes from CWS dba32a herein 2009-04-02 12:00:42 +0200 fs r270391 : merge changes from CWS dba32a herein 2009-04-02 11:47:26 +0200 fs r270390 : merge changes from CWS dba32a herein 2009-04-02 11:39:15 +0200 oj r270389 : #i94467# foxpro impl several new types 2009-04-02 11:35:58 +0200 fs r270387 : merge changes from CWS dba32a herein 2009-04-01 14:10:51 +0200 fs r270329 : merge changes from CWS dba32a herein 2009-03-31 17:29:50 +0200 fs r270290 : merge changes from CWS dba32a herein 2009-03-30 14:53:56 +0200 fs r270233 : #i100417# don't set grid column widths to 0, but to <void/> 2009-03-30 12:31:03 +0200 oj r270213 : #i100552# wrong orb used 2009-03-30 12:19:20 +0200 oj r270212 : #i98303# convertlike corrected to sal_Unicode 2009-03-30 11:58:25 +0200 fs r270210 : merge changes from CWS dba32a herein 2009-03-30 11:38:16 +0200 oj r270205 : remove duplicate code from merge 2009-03-30 11:02:27 +0200 fs r270202 : merge changes from CWS dba32a herein 2009-03-30 11:02:19 +0200 fs r270201 : merge changes from CWS dba32a herein 2009-03-30 10:31:26 +0200 oj r270200 : #i100665# only throw exception and do not drop table 2009-03-30 09:36:24 +0200 fs r270195 : assertion text 2009-03-28 20:21:58 +0100 fs r270187 : #ii10000# 2009-03-28 20:19:54 +0100 fs r270186 : removed unused help ids 2009-03-28 20:19:40 +0100 fs r270185 : removed unused help ids 2009-03-28 20:19:10 +0100 fs r270184 : #i100237# +DefaultState/XReset 2009-03-28 00:29:29 +0100 fs r270177 : CWS-TOOLING: rebase CWS dba32b to trunk@270033 (milestone: DEV300:m45) 2009-03-27 22:56:46 +0100 fs r270173 : #i100237# DEFAULT_CHECKED -> DEFAULT_STATE 2009-03-27 22:55:52 +0100 fs r270172 : #i100237# DefaultState property for buttons, enabled only when Toggle=Yes 2009-03-27 22:54:15 +0100 fs r270171 : #i100237# DEFAULT_CHECKED -> DEFAULT_STATE 2009-03-27 22:53:54 +0100 fs r270170 : #i100237# introduce a DefaultState property for buttons, which implies buttongs supporting XReset, which needed some refactoring 2009-03-27 13:31:41 +0100 fs r270152 : ignore output paths 2009-03-27 11:23:44 +0100 fs r270139 : tuned behavior with respect to invalid keys/values 2009-03-27 09:57:14 +0100 fs r270136 : don't allow Double.NaN 2009-03-27 09:56:16 +0100 fs r270135 : talk about Double.NaN 2009-03-26 12:14:30 +0100 fs r270067 : removed unused parameter 2009-03-26 12:14:02 +0100 fs r270066 : removed widening conversion when checking keys 2009-03-26 09:17:34 +0100 fs r270053 : separated the enumerator functionality into a dedicated interface, this way not burdening XMap with it 2009-03-26 09:17:11 +0100 fs r270052 : separated the enumerator functionality into a dedicated interface, this way not burdening XMap with it 2009-03-26 09:16:49 +0100 fs r270051 : separated the enumerator functionality into a dedicated interface, this way not burdening XMap with it 2009-03-25 21:55:20 +0100 fs r270044 : #i100541# properly calculat bNeedScrollBox 2009-03-25 12:56:17 +0100 fs r270019 : renamed the previously introduced error condition 2009-03-25 12:11:48 +0100 fs r270015 : #i100095# when the error messages contain non-trivial details (SQLState/ErrorCode), then always display the 'Details' button 2009-03-25 12:10:05 +0100 fs r270012 : renamed the previously introduced error condition 2009-03-25 12:01:04 +0100 fs r270011 : #i100095# when no address book (or respective profile) can be found, then use a dedicated ErrorCondition 2009-03-25 10:29:07 +0100 fs r270003 : add missing localization 2009-03-25 10:23:12 +0100 fs r270001 : in preparation of #i1000095#: rework the error handling, allow using css.sdb.ErrorCondition values, plus allow propagating the nsresult 2009-03-25 10:21:55 +0100 fs r270000 : in preparation of #i1000095#: rework the error handling, allow using css.sdb.ErrorCondition values, plus allow propagating the nsresult 2009-03-20 23:05:38 +0100 fs r269829 : XMap::getSize removed 2009-03-20 23:05:19 +0100 fs r269828 : changes as suggested by sb 2009-03-20 23:04:56 +0100 fs r269827 : enhanced documentation 2009-03-20 15:31:40 +0100 fs r269815 : changes as suggested by sb 2009-03-20 13:23:52 +0100 oj r269804 : #i92538# correct the zorder that fixedtext is infront of control 2009-03-20 12:59:38 +0100 oj r269801 : #i94571# paraadjust now supports BLOCK 2009-03-20 12:58:11 +0100 oj r269800 : #i94571# export style with data style 2009-03-20 12:57:05 +0100 oj r269799 : #i94571# text align is now paraadjust 2009-03-20 12:37:02 +0100 fs r269797 : enum keys only accepted if they have the exact type, not if they have *any* enum type 2009-03-20 12:28:31 +0100 fs r269794 : some changes requested by sb 2009-03-20 08:52:47 +0100 fs r269780 : doc 2009-03-20 07:37:31 +0100 oj r269779 : #i99913# only notifiy when values are different 2009-03-20 07:36:58 +0100 oj r269778 : #i99913# add undoenv as listener at the dataprovider 2009-03-19 22:52:52 +0100 fs r269771 : added comment 2009-03-19 22:40:06 +0100 fs r269770 : +testEnumeration 2009-03-19 22:39:41 +0100 fs r269769 : implemented enumeration, getKeySet, and getValues. Should be finished now. 2009-03-19 14:01:01 +0100 oj r269743 : #i99913# reset the modified state when selecting an object 2009-03-19 12:19:54 +0100 lla r269739 : #i72390# cleanups 2009-03-19 09:25:27 +0100 fs r269727 : #i10000# 2009-03-18 23:37:02 +0100 fs r269708 : extended checks for value type acceptance 2009-03-18 23:36:41 +0100 fs r269707 : fixed value type checks 2009-03-18 14:59:56 +0100 fs r269678 : initial complex test case for the new css.container.Map implementation 2009-03-18 14:59:24 +0100 fs r269677 : verifyExpectedException moved to base class (in complexlib), and renamed to assureException for consistency 2009-03-18 14:58:35 +0100 fs r269676 : removed unused imports 2009-03-18 14:58:03 +0100 fs r269675 : first implementation of the new css.container.Map service (not completed, yet) 2009-03-18 14:57:17 +0100 fs r269674 : base class for UNO components, freeing you from some repeating work 2009-03-18 14:55:53 +0100 fs r269672 : +assureException: call a given method with given parameters on a given object, ensure that a given exception is thrown by the method implementation 2009-03-18 14:54:58 +0100 fs r269671 : +getComponentContext 2009-03-18 14:54:00 +0100 fs r269670 : isEmpty returns a boolean, not a long 2009-03-18 14:14:43 +0100 oj r269663 : #i99743# now text also supports null 2009-03-18 13:54:14 +0100 oj r269660 : #i99223# remove check for 2 params 2009-03-18 13:33:35 +0100 oj r269659 : #i99060# replace text::ParagraphVertAlign with style::VerticalAlignment 2009-03-18 13:32:18 +0100 oj r269658 : #i99060# don't set void property when void isn't allowed 2009-03-18 13:31:11 +0100 oj r269657 : #i99060# handle vertical alignment 2009-03-18 13:28:28 +0100 oj r269656 : #i99060# remove unused elements from sytle 2009-03-18 09:35:42 +0100 lla r269639 : #i72390# cleanups 2009-03-18 09:31:20 +0100 lla r269638 : #i72390# add ButtonList 2009-03-18 09:30:46 +0100 lla r269637 : #i72390# renamed interface 2009-03-18 09:30:15 +0100 lla r269636 : #i72390# use ButtonList instead of ImageList 2009-03-18 09:29:05 +0100 lla r269635 : #i72390# new ButtonList, cleanups 2009-03-18 09:26:34 +0100 lla r269634 : #i72390# cleanups 2009-03-17 12:21:20 +0100 oj r269590 : #i99222# remove assertion 2009-03-17 12:17:22 +0100 oj r269589 : #i98605# impl scale mode 2009-03-17 12:10:42 +0100 oj r269588 : #i98605# impl scale mode 2009-03-17 11:40:15 +0100 oj r269584 : #i96944# doesn't create equation for shapes 2009-03-17 11:33:16 +0100 oj r269583 : #i96423# switch calc from float to long 2009-03-16 15:19:18 +0100 fs r269550 : #i41930# enable zoom for embedded/outplace documents 2009-03-16 14:25:54 +0100 oj r269542 : #i93734# remove ContextSensitive 2009-03-16 14:21:58 +0100 oj r269541 : #i99274# page header before group header 2009-03-16 14:18:23 +0100 oj r269539 : #i99110# fix value type 2009-03-16 14:14:16 +0100 fs r269537 : line ends 2009-03-16 14:11:06 +0100 fs r269535 : line ends 2009-03-16 14:08:34 +0100 fs r269534 : #i100087# (provided my np): allow for polymorphic types with more than one parameter 2009-03-16 12:30:31 +0100 oj r269521 : compile error 2009-03-16 12:19:12 +0100 oj r269519 : compile error 2009-03-16 10:39:28 +0100 oj r269511 : compile error under linux with swap 2009-03-13 10:33:04 +0100 oj r269462 : CWS-TOOLING: rebase CWS dba32b to trunk@269297 (milestone: DEV300:m43) 2009-03-12 14:37:25 +0100 fs r269416 : interface SequenceOutputStreamTest is unneeded, and pollutes the namespace here :) 2009-03-12 14:35:07 +0100 fs r269414 : not needed 2009-03-12 14:34:15 +0100 fs r269413 : preparation for multiple tests in this module 2009-03-12 14:33:02 +0100 fs r269412 : ShowTargets was moved from module integration.forms to module complexlib 2009-03-12 14:32:48 +0100 fs r269411 : helper class for projects containing multiple complex test cases (and following a certain structure) 2009-03-12 14:00:14 +0100 fs r269407 : proper module after the move 2009-03-12 13:59:10 +0100 fs r269406 : superseded by ../makefile.mk 2009-03-12 13:47:38 +0100 fs r269403 : not needed anymore 2009-03-12 13:45:46 +0100 fs r269402 : moved, in preparation of adding more test cases here, with a common infrastructure 2009-03-12 13:45:07 +0100 fs r269401 : moved from ../ 2009-03-12 13:43:59 +0100 fs r269400 : moved to ./comphelper, in preparation of adding more test cases here, with a common infrastructure 2009-03-12 13:29:47 +0100 oj r269396 : #i99914# set parent on dataprovider 2009-03-12 13:10:35 +0100 oj r269393 : #i99832# check thrown exception and show error 2009-03-12 13:08:10 +0100 fs r269392 : reorganizing tests 2009-03-12 12:52:55 +0100 oj r269390 : #i99118# convert formatkey in numberformat 2009-03-12 12:34:53 +0100 fs r269388 : new API tests 2009-03-12 12:29:05 +0100 fs r269386 : Map not yet committed 2009-03-12 12:28:36 +0100 fs r269385 : oops, forgot the SequenceInputStream during the previous refactoring 2009-03-12 12:12:39 +0100 oj r269384 : #i99104# set HasCategories prop 2009-03-12 12:12:08 +0100 oj r269383 : #i99104# check HasCategories even for internal dataprovider 2009-03-12 12:10:40 +0100 oj r269382 : #i99104# set HasCategories prop 2009-03-12 10:51:49 +0100 fs r269373 : #i10000# exception specifications 2009-03-12 10:49:18 +0100 fs r269372 : #i10000# exception specifications 2009-03-12 10:44:02 +0100 fs r269371 : #i10000# exception specifications 2009-03-12 10:30:55 +0100 fs r269368 : refactored the UNO service registration in this module, using the helper classes provided by comphelper itself, so you have less effort when extending the list of to-be-registered components 2009-03-12 10:30:37 +0100 fs r269367 : module-local includes 2009-03-12 07:05:54 +0100 oj r269357 : #i99104# database dataprovider doesn't need dataranges and diagramdata 2009-03-11 10:58:28 +0100 oj r269306 : #i99911# check if name of the report is a valid file name 2009-03-11 10:03:23 +0100 oj r269299 : #i99666# the report is new when the HierarchicalDocumentName is empty 2009-03-10 11:32:45 +0100 oj r269258 : #i99221# use fallback for language 2009-03-10 10:48:40 +0100 oj r269255 : #i99433# now use OStringBuffer 2009-03-10 10:36:21 +0100 fs r269252 : initial version of (X)Map 2009-03-10 09:52:23 +0100 oj r269246 : #i99433# now use OStringBuffer 2009-03-10 08:56:13 +0100 oj r269240 : #i99655# patch applied 2009-03-09 07:35:33 +0100 lla r269058 : #i10000# wrong variable assignment fixed 2009-03-06 17:20:40 +0100 fs r269030 : some explicit defaults 2009-03-06 17:20:30 +0100 fs r269029 : #i98600# 2009-03-06 14:40:34 +0100 fs r269009 : #i87692# during reload, prevent the document being modified just because of some control content changes ... 2009-03-06 12:52:20 +0100 lla r268997 : #i10000# ambigous problem with FontWeight fixed 2009-03-06 11:39:32 +0100 fs r268989 : #i10000# (approved by pl): use --without-t1-library configure option 2009-03-06 10:55:43 +0100 fs r268986 : #i99953# depends on xmlscript module now 2009-03-06 10:54:04 +0100 fs r268985 : #i99953# also adjust the event names found in dialogs embedded in the forms 2009-03-06 09:53:41 +0100 fs r268977 : #i10000# 2009-03-06 09:30:41 +0100 lla r268973 : #i10000# merge problems 2009-03-05 17:52:34 +0100 fs r268932 : #i98593# for sub components which are actually controlled by a DocumentDefinition (aka XComponentSupplier aka XCommandProcessor), close them by executing the 'close' command, not by suspending/closing the controller (which cannot be intercepted) 2009-03-05 11:41:56 +0100 fs r268889 : default the drop down line count for list/combo boxes to 20 2009-03-05 11:39:10 +0100 fs r268887 : do not display empty error messages 2009-03-02 10:13:57 +0100 lla r268639 : #i91541# CWS rebase m41 to m42 2009-03-02 09:06:27 +0100 lla r268635 : #i10000# add ';' to strings 2009-02-26 11:18:00 +0100 fs r268492 : reportdesign depends on REPORTBUILDER, not REPORTDESIGN 2009-02-26 10:11:38 +0100 lla r268489 : CWS-TOOLING: rebase CWS dba32b to trunk@268395 (milestone: DEV300:m42) 2009-02-26 09:04:11 +0100 lla r268488 : CWS-TOOLING: rebase CWS dba32b to trunk@268395 (milestone: DEV300:m42) 2009-02-24 12:09:13 +0100 lla r268392 : #i91541# #i91542# cleanups 2009-02-24 08:08:06 +0100 lla r268382 : merge all dba32a changes into dba32b 2009-02-24 07:14:55 +0100 lla r268381 : merge all dba32a changes into dba32b 2009-02-23 21:44:28 +0100 fs r268377 : oops ... don't tamper with m_aListSourceValues at the end of loadData 2009-02-23 20:57:05 +0100 fs r268376 : #i98162# don't hold the values as strings, but as ORowSetValue, this way preserving their type, and being agnostic to different result/rowset implementations doing different to-string-conversations 2009-02-23 20:55:44 +0100 fs r268375 : getObject: throwFunctionNotSupportedException, instead of silently returning NULL 2009-02-23 20:55:20 +0100 fs r268374 : #i98162# some more supported types 2009-02-23 20:54:43 +0100 fs r268373 : #i98162# +operator != 2009-02-20 09:35:39 +0100 fs r268306 : #i99422# for a font, display the font name, the style, and the size 2009-02-20 09:33:45 +0100 fs r268305 : #i99422# in the property browser, FONT supersedes CHARFONTNAME: the aggregated FormComponentHandler displays them more nicely now 2009-02-19 16:12:06 +0100 fs r268293 : #i99372# recognize DataType::FLOAT as numeric 2009-02-19 15:43:12 +0100 fs r268291 : #i99415# 2009-02-19 15:40:15 +0100 fs r268290 : #i99242# lcl_firstFocussableControl: take disabled controls into account 2009-02-19 15:34:36 +0100 fs r268289 : #i99396# properly decode the base name of the URL when using it as title 2009-02-19 15:19:05 +0100 fs r268287 : #i98247#
Diffstat (limited to 'reportdesign')
-rw-r--r--reportdesign/inc/ReportDefinition.hxx40
-rw-r--r--reportdesign/inc/ReportHelperDefines.hxx4
-rw-r--r--reportdesign/inc/RptDef.hxx16
-rw-r--r--reportdesign/inc/RptObject.hxx3
-rw-r--r--reportdesign/inc/RptResId.hrc5
-rw-r--r--reportdesign/inc/helpids.hrc4
-rw-r--r--reportdesign/source/core/api/ReportComponent.cxx7
-rw-r--r--reportdesign/source/core/api/ReportDefinition.cxx247
-rw-r--r--reportdesign/source/core/api/ReportEngineJFree.cxx56
-rw-r--r--reportdesign/source/core/inc/ReportControlModel.hxx2
-rw-r--r--reportdesign/source/core/inc/ReportEngineJFree.hxx3
-rw-r--r--reportdesign/source/core/inc/ReportHelperImpl.hxx20
-rw-r--r--reportdesign/source/core/inc/Tools.hxx18
-rw-r--r--reportdesign/source/core/sdr/PropertyForward.cxx18
-rw-r--r--reportdesign/source/core/sdr/RptObject.cxx184
-rw-r--r--reportdesign/source/core/sdr/RptPage.cxx4
-rw-r--r--reportdesign/source/core/sdr/UndoActions.cxx3
-rw-r--r--reportdesign/source/filter/xml/xmlExport.cxx68
-rw-r--r--reportdesign/source/filter/xml/xmlExportDocumentHandler.cxx46
-rw-r--r--reportdesign/source/filter/xml/xmlExportDocumentHandler.hxx2
-rw-r--r--reportdesign/source/filter/xml/xmlHelper.cxx81
-rw-r--r--reportdesign/source/filter/xml/xmlHelper.hxx4
-rw-r--r--reportdesign/source/filter/xml/xmlImage.cxx16
-rw-r--r--reportdesign/source/filter/xml/xmlImportDocumentHandler.cxx52
-rw-r--r--reportdesign/source/filter/xml/xmlImportDocumentHandler.hxx2
-rw-r--r--reportdesign/source/filter/xml/xmlPropertyHandler.cxx2
-rw-r--r--reportdesign/source/filter/xml/xmlfilter.cxx4
-rw-r--r--reportdesign/source/inc/stringconstants.hrc2
-rw-r--r--reportdesign/source/inc/uistrings.hrc1
-rw-r--r--reportdesign/source/shared/stringconstants.cxx8
-rw-r--r--reportdesign/source/shared/uistrings.cxx1
-rw-r--r--reportdesign/source/ui/dlg/AddField.cxx1
-rw-r--r--reportdesign/source/ui/inc/ReportController.hxx15
-rw-r--r--reportdesign/source/ui/inc/ReportControllerObserver.hxx3
-rw-r--r--reportdesign/source/ui/inc/metadata.hxx9
-rw-r--r--reportdesign/source/ui/inspection/DataProviderHandler.cxx8
-rw-r--r--reportdesign/source/ui/inspection/GeometryHandler.cxx70
-rw-r--r--reportdesign/source/ui/inspection/inspection.src43
-rw-r--r--reportdesign/source/ui/inspection/metadata.cxx10
-rw-r--r--reportdesign/source/ui/misc/UITools.cxx147
-rw-r--r--reportdesign/source/ui/report/ReportController.cxx161
-rw-r--r--reportdesign/source/ui/report/ViewsWindow.cxx14
-rw-r--r--reportdesign/source/ui/report/propbrw.cxx1
-rw-r--r--reportdesign/uiconfig/dbreport/menubar/menubar.xml90
-rw-r--r--reportdesign/uiconfig/dbreport/toolbar/Formatting.xml1
-rw-r--r--reportdesign/util/hidother.src10
46 files changed, 1048 insertions, 458 deletions
diff --git a/reportdesign/inc/ReportDefinition.hxx b/reportdesign/inc/ReportDefinition.hxx
index 2223cf443051..ec9a5c4f5248 100644
--- a/reportdesign/inc/ReportDefinition.hxx
+++ b/reportdesign/inc/ReportDefinition.hxx
@@ -33,7 +33,7 @@
#include "dllapi.h"
#include <com/sun/star/report/XReportDefinition.hpp>
-#include <cppuhelper/compbase11.hxx>
+#include <cppuhelper/compbase12.hxx>
#include <cppuhelper/basemutex.hxx>
#include <com/sun/star/lang/XServiceInfo.hpp>
#include <com/sun/star/lang/XUnoTunnel.hpp>
@@ -41,13 +41,15 @@
#include <com/sun/star/frame/XTitle.hpp>
#include <com/sun/star/frame/XTitleChangeBroadcaster.hpp>
#include <com/sun/star/frame/XUntitledNumbers.hpp>
+#include <com/sun/star/frame/XModule.hpp>
+#include <com/sun/star/util/XNumberFormatsSupplier.hpp>
#include <com/sun/star/document/XDocumentPropertiesSupplier.hpp>
+#include <com/sun/star/datatransfer/XTransferable.hpp>
#include <cppuhelper/propertysetmixin.hxx>
#include <comphelper/uno3.hxx>
#include <comphelper/embeddedobjectcontainer.hxx>
#include <svx/unomod.hxx>
-#include <com/sun/star/util/XNumberFormatsSupplier.hpp>
-#include <com/sun/star/frame/XModule.hpp>
+
#include "ReportHelperDefines.hxx"
#include <boost/shared_ptr.hpp>
@@ -63,7 +65,7 @@ namespace comphelper
namespace reportdesign
{
class OReportComponentProperties;
- typedef ::cppu::WeakComponentImplHelper11< com::sun::star::report::XReportDefinition
+ typedef ::cppu::WeakComponentImplHelper12< com::sun::star::report::XReportDefinition
,com::sun::star::document::XEventBroadcaster
,com::sun::star::lang::XServiceInfo
,com::sun::star::frame::XModule
@@ -73,6 +75,7 @@ namespace reportdesign
,::com::sun::star::frame::XTitleChangeBroadcaster
,::com::sun::star::frame::XUntitledNumbers
,::com::sun::star::document::XDocumentPropertiesSupplier
+ ,::com::sun::star::datatransfer::XTransferable
,SvxUnoDrawMSFactory> ReportDefinitionBase;
typedef ::cppu::PropertySetMixin<com::sun::star::report::XReportDefinition> ReportDefinitionPropertySet;
@@ -145,6 +148,17 @@ namespace reportdesign
::com::sun::star::uno::Reference< ::com::sun::star::frame::XTitle > impl_getTitleHelper_throw();
::com::sun::star::uno::Reference< ::com::sun::star::frame::XUntitledNumbers > impl_getUntitledHelper_throw();
+
+ /** loads the report definition from the given storage
+ @precond
+ our mutex is locked
+ @throws
+ */
+ void impl_loadFromStorage_nolck_throw(
+ const ::com::sun::star::uno::Reference< ::com::sun::star::embed::XStorage >& _rxStorage,
+ const ::com::sun::star::uno::Sequence< ::com::sun::star::beans::PropertyValue >& _rArguments
+ );
+
protected:
virtual ~OReportDefinition();
@@ -359,6 +373,11 @@ namespace reportdesign
// XDocumentPropertiesSupplier
virtual ::com::sun::star::uno::Reference< ::com::sun::star::document::XDocumentProperties > SAL_CALL getDocumentProperties( ) throw (::com::sun::star::uno::RuntimeException);
+ // XTransferable
+ virtual ::com::sun::star::uno::Any SAL_CALL getTransferData( const ::com::sun::star::datatransfer::DataFlavor& aFlavor ) throw (::com::sun::star::datatransfer::UnsupportedFlavorException, ::com::sun::star::io::IOException, ::com::sun::star::uno::RuntimeException);
+ virtual ::com::sun::star::uno::Sequence< ::com::sun::star::datatransfer::DataFlavor > SAL_CALL getTransferDataFlavors( ) throw (::com::sun::star::uno::RuntimeException);
+ virtual ::sal_Bool SAL_CALL isDataFlavorSupported( const ::com::sun::star::datatransfer::DataFlavor& aFlavor ) throw (::com::sun::star::uno::RuntimeException);
+
// comphelper::IEmbeddedHelper
virtual com::sun::star::uno::Reference < com::sun::star::embed::XStorage > getStorage() const;
virtual ::comphelper::EmbeddedObjectContainer& getEmbeddedObjectContainer() const;
@@ -366,19 +385,6 @@ namespace reportdesign
virtual bool isEnableSetModified() const;
::com::sun::star::uno::Reference< ::com::sun::star::uno::XComponentContext > getContext() const;
-
- private:
- /** loads the report definition from the given storage
-
- @precond
- our mutex is locked
- @throws
- */
- void impl_loadFromStorage_nolck_throw(
- const ::com::sun::star::uno::Reference< ::com::sun::star::embed::XStorage >& _rxStorage,
- const ::com::sun::star::uno::Sequence< ::com::sun::star::beans::PropertyValue >& _rArguments
- );
-
};
// =============================================================================
} // namespace reportdesign
diff --git a/reportdesign/inc/ReportHelperDefines.hxx b/reportdesign/inc/ReportHelperDefines.hxx
index 939c98115b9f..6be7ae969300 100644
--- a/reportdesign/inc/ReportHelperDefines.hxx
+++ b/reportdesign/inc/ReportHelperDefines.hxx
@@ -143,8 +143,8 @@
virtual void SAL_CALL setCharRotation( ::sal_Int16 _charrotation ) throw (::com::sun::star::beans::UnknownPropertyException, ::com::sun::star::uno::RuntimeException);\
virtual ::sal_Int16 SAL_CALL getCharScaleWidth() throw (::com::sun::star::beans::UnknownPropertyException, ::com::sun::star::uno::RuntimeException);\
virtual void SAL_CALL setCharScaleWidth( ::sal_Int16 _charscalewidth ) throw (::com::sun::star::beans::UnknownPropertyException, ::com::sun::star::uno::RuntimeException);\
- virtual ::sal_Int16 SAL_CALL getParaVertAlignment() throw (::com::sun::star::uno::RuntimeException);\
- virtual void SAL_CALL setParaVertAlignment( ::sal_Int16 _paravertalignment ) throw (::com::sun::star::lang::IllegalArgumentException, ::com::sun::star::uno::RuntimeException);\
+ virtual ::com::sun::star::style::VerticalAlignment SAL_CALL getVerticalAlign() throw (::com::sun::star::beans::UnknownPropertyException,::com::sun::star::uno::RuntimeException);\
+ virtual void SAL_CALL setVerticalAlign( ::com::sun::star::style::VerticalAlignment _paravertalignment ) throw (::com::sun::star::lang::IllegalArgumentException, ::com::sun::star::beans::UnknownPropertyException, ::com::sun::star::uno::RuntimeException);\
virtual ::rtl::OUString SAL_CALL getHyperLinkURL() throw (::com::sun::star::beans::UnknownPropertyException, ::com::sun::star::uno::RuntimeException);\
virtual void SAL_CALL setHyperLinkURL( const ::rtl::OUString& _hyperlinkurl ) throw (::com::sun::star::beans::UnknownPropertyException, ::com::sun::star::uno::RuntimeException);\
virtual ::rtl::OUString SAL_CALL getHyperLinkTarget() throw (::com::sun::star::beans::UnknownPropertyException, ::com::sun::star::uno::RuntimeException);\
diff --git a/reportdesign/inc/RptDef.hxx b/reportdesign/inc/RptDef.hxx
index 9b30bef5ade3..31aaa2062305 100644
--- a/reportdesign/inc/RptDef.hxx
+++ b/reportdesign/inc/RptDef.hxx
@@ -37,6 +37,7 @@
#include <comphelper/stl_types.hxx>
#include <comphelper/uno3.hxx>
#include <svx/fmglob.hxx>
+#include <boost/shared_ptr.hpp>
FORWARD_DECLARE_INTERFACE(report,XReportComponent)
@@ -81,13 +82,22 @@ namespace ControlModification
static const ::sal_Int32 HEIGHT_GREATEST = (sal_Int32)10;
}
+class AnyConverter : public ::std::binary_function< ::rtl::OUString,::com::sun::star::uno::Any,::com::sun::star::uno::Any >
+{
+public:
+ virtual ~AnyConverter(){}
+ virtual ::com::sun::star::uno::Any operator() (const ::rtl::OUString& /*_sPropertyName*/,const ::com::sun::star::uno::Any& lhs) const
+ {
+ return lhs;
+ }
+};
/** returns teh object type depending on the service name
@param _xComponent the report component
*/
REPORTDESIGN_DLLPUBLIC sal_uInt16 getObjectType(const ::com::sun::star::uno::Reference< ::com::sun::star::report::XReportComponent>& _xComponent);
-
-DECLARE_STL_USTRINGACCESS_MAP(::rtl::OUString , TPropertyNamePair);
-/** returns teh property name map for the givern property id
+typedef ::std::pair< ::rtl::OUString, ::boost::shared_ptr<AnyConverter> > TPropertyConverter;
+DECLARE_STL_USTRINGACCESS_MAP(TPropertyConverter , TPropertyNamePair);
+/** returns the property name map for the givern property id
@param _nObjectId the object id
*/
REPORTDESIGN_DLLPUBLIC const TPropertyNamePair& getPropertyNameMap(sal_uInt16 _nObjectId);
diff --git a/reportdesign/inc/RptObject.hxx b/reportdesign/inc/RptObject.hxx
index 87778659ea23..8415fd128e1d 100644
--- a/reportdesign/inc/RptObject.hxx
+++ b/reportdesign/inc/RptObject.hxx
@@ -125,6 +125,7 @@ public:
void EndListening(sal_Bool bRemoveListener = sal_True);
// PropertyChangeListener
virtual void _propertyChange( const ::com::sun::star::beans::PropertyChangeEvent& evt ) throw(::com::sun::star::uno::RuntimeException);
+ virtual void initializeOle() {}
sal_Bool supportsService( const ::rtl::OUString& _sServiceName ) const;
@@ -193,6 +194,7 @@ class REPORTDESIGN_DLLPUBLIC OOle2Obj: public SdrOle2Obj , public OObjectBase
friend class DlgEdFactory;
UINT16 m_nType;
+ bool m_bOnlyOnce;
void impl_createDataProvider_nothrow( const ::com::sun::star::uno::Reference< ::com::sun::star::frame::XModel>& _xModel);
public:
static OOle2Obj* Create( const ::com::sun::star::uno::Reference< ::com::sun::star::report::XReportComponent>& _xComponent,UINT16 _nType )
@@ -227,6 +229,7 @@ public:
virtual UINT32 GetObjInventor() const;
// Clone() soll eine komplette Kopie des Objektes erzeugen.
virtual SdrObject* Clone() const;
+ virtual void initializeOle();
void initializeChart( const ::com::sun::star::uno::Reference< ::com::sun::star::frame::XModel>& _xModel);
};
diff --git a/reportdesign/inc/RptResId.hrc b/reportdesign/inc/RptResId.hrc
index c87ae1a9c216..c9cc382ca253 100644
--- a/reportdesign/inc/RptResId.hrc
+++ b/reportdesign/inc/RptResId.hrc
@@ -229,11 +229,12 @@
#define RID_STR_AREA (RID_STRING_START + 153)
#define RID_STR_INSERT (RID_STRING_START + 154)
#define RID_STR_UNDO_SHRINK (RID_STRING_START + 155)
-
#define RID_STR_F_COUNTER (RID_STRING_START + 156)
#define RID_STR_F_ACCUMULATION (RID_STRING_START + 157)
#define RID_STR_F_MINIMUM (RID_STRING_START + 158)
#define RID_STR_F_MAXIMUM (RID_STRING_START + 159)
+#define RID_STR_VERTICALALIGN (RID_STRING_START + 160)
+#define RID_STR_PARAADJUST (RID_STRING_START + 161)
// #define RID_STR_ (RID_STRING_START + 130)
@@ -287,6 +288,8 @@
#define RID_STR_REPORTPRINTOPTION_CONST (RID_UNTYPED_START + 4)
#define RID_STR_SECTIONPAGEBREAK_CONST (RID_UNTYPED_START + 5)
#define RID_STR_TYPE_CONST (RID_UNTYPED_START + 6)
+#define RID_STR_VERTICAL_ALIGN_CONST (RID_UNTYPED_START + 7)
+#define RID_STR_PARAADJUST_CONST (RID_UNTYPED_START + 8)
// toolbox lists ---------------------------------------------------------------------
diff --git a/reportdesign/inc/helpids.hrc b/reportdesign/inc/helpids.hrc
index 6026634499a1..b60f66823623 100644
--- a/reportdesign/inc/helpids.hrc
+++ b/reportdesign/inc/helpids.hrc
@@ -81,11 +81,11 @@
// free
#define HID_RPT_PROP_PRINTREPEATEDVALUES (HID_RPT_START + 44)
#define HID_RPT_PROP_CONDITIONALPRINTEXPRESSION (HID_RPT_START + 45)
-// free
+#define HID_RPT_PROP_VERTICALALIGN (HID_RPT_START + 46)
#define HID_RPT_PROP_STARTNEWCOLUMN (HID_RPT_START + 47)
#define HID_RPT_PROP_STARTNEWPAGE (HID_RPT_START + 48)
#define HID_RPT_PROP_RESETPAGENUMBER (HID_RPT_START + 49)
-// free
+#define HID_RPT_PROP_PARAADJUST (HID_RPT_START + 50)
#define HID_RPT_PROP_MINHEIGHTNEWPAGE (HID_RPT_START + 51)
#define HID_RPT_PROP_PRINTWHENGROUPCHANGE (HID_RPT_START + 52)
#define HID_RPT_PROP_CHARTTYPE (HID_RPT_START + 53)
diff --git a/reportdesign/source/core/api/ReportComponent.cxx b/reportdesign/source/core/api/ReportComponent.cxx
index 8b9b498fe72d..c90407c156de 100644
--- a/reportdesign/source/core/api/ReportComponent.cxx
+++ b/reportdesign/source/core/api/ReportComponent.cxx
@@ -41,7 +41,7 @@
#include "ReportControlModel.hxx"
#include <com/sun/star/reflection/XProxyFactory.hpp>
#include <com/sun/star/text/ParagraphVertAlign.hpp>
-// #include <svx/unoshape.hxx>
+#include <com/sun/star/style/ParagraphAdjust.hpp>
#include <svx/unolingu.hxx>
#include <svtools/syslocale.hxx>
#include <svtools/lingucfg.hxx>
@@ -73,14 +73,14 @@ void lcl_getDefaultFonts( Font& rLatinFont, Font& rCJKFont, Font& rCTLFont,Langu
rCTLFont = OutputDevice::GetDefaultFont( DEFAULTFONT_CTL_PRESENTATION, _eCTL, DEFAULTFONT_FLAGS_ONLYONE ) ;
}
OFormatProperties::OFormatProperties()
- :nAlign(0)
+ :nAlign(style::ParagraphAdjust_LEFT)
,nFontEmphasisMark(0)
,nFontRelief(0)
,nTextColor(0)
,nTextLineColor(0)
,nCharUnderlineColor(0xFFFFFFFF)
,nBackgroundColor(COL_TRANSPARENT)
- ,aVerticalAlignment(text::ParagraphVertAlign::TOP)
+ ,aVerticalAlignment( style::VerticalAlignment_TOP )
,nCharEscapement(0)
,nCharCaseMap(0)
,nCharKerning(0)
@@ -114,7 +114,6 @@ OFormatProperties::OFormatProperties()
}
aFontDescriptor.Weight = awt::FontWeight::NORMAL;
aFontDescriptor.CharacterWidth = awt::FontWidth::NORMAL;
-
// aCharLocale = SvtSysLocale().GetLocaleData().getLocale();
}
// -----------------------------------------------------------------------------
diff --git a/reportdesign/source/core/api/ReportDefinition.cxx b/reportdesign/source/core/api/ReportDefinition.cxx
index c85e754eb63c..d6b22a007409 100644
--- a/reportdesign/source/core/api/ReportDefinition.cxx
+++ b/reportdesign/source/core/api/ReportDefinition.cxx
@@ -39,26 +39,35 @@
#include <com/sun/star/style/GraphicLocation.hpp>
#include <com/sun/star/xml/AttributeData.hpp>
#include <com/sun/star/lang/XSingleServiceFactory.hpp>
-#include <comphelper/namecontainer.hxx>
#include <comphelper/broadcasthelper.hxx>
+#include <comphelper/documentconstants.hxx>
+#include <comphelper/genericpropertyset.hxx>
+#include <comphelper/mediadescriptor.hxx>
+#include <comphelper/mimeconfighelper.hxx>
+#include <comphelper/namecontainer.hxx>
+#include <comphelper/namedvaluecollection.hxx>
+#include <comphelper/numberedcollection.hxx>
+#include <comphelper/propertystatecontainer.hxx>
+#include <comphelper/proparrhlp.hxx>
+#include <comphelper/property.hxx>
+#include <comphelper/propertysetinfo.hxx>
#include <comphelper/sequence.hxx>
+#include <comphelper/seqstream.hxx>
#include <comphelper/storagehelper.hxx>
+#include <comphelper/uno3.hxx>
#include <com/sun/star/chart2/data/DatabaseDataProvider.hpp>
#include <vcl/svapp.hxx>
+#include <vcl/virdev.hxx>
#include <vos/mutex.hxx>
-#include <comphelper/uno3.hxx>
-#include <comphelper/propertystatecontainer.hxx>
-#include <comphelper/namedvaluecollection.hxx>
-#include <comphelper/proparrhlp.hxx>
#include <com/sun/star/beans/XMultiPropertyStates.hpp>
#include <com/sun/star/document/EventObject.hpp>
#include <com/sun/star/document/XEventListener.hpp>
#include <com/sun/star/style/XStyle.hpp>
-#include <comphelper/documentconstants.hxx>
#include <com/sun/star/embed/XTransactedObject.hpp>
#include <com/sun/star/embed/ElementModes.hpp>
#include <com/sun/star/embed/EmbedMapUnits.hpp>
#include <com/sun/star/embed/EntryInitModes.hpp>
+#include <com/sun/star/embed/Aspects.hpp>
#include <com/sun/star/io/XActiveDataSource.hpp>
#include <com/sun/star/embed/ElementModes.hpp>
#include <com/sun/star/io/XSeekable.hpp>
@@ -71,6 +80,8 @@
#include <com/sun/star/document/XFilter.hpp>
#include <com/sun/star/task/ErrorCodeIOException.hpp>
#include <com/sun/star/xml/sax/XDocumentHandler.hpp>
+#include <com/sun/star/frame/XComponentLoader.hpp>
+#include <com/sun/star/frame/FrameSearchFlag.hpp>
#include "corestrings.hrc"
#include "Groups.hxx"
#include "RptDef.hxx"
@@ -81,14 +92,10 @@
#include "Tools.hxx"
#include <tools/debug.hxx>
#include <tools/diagnose_ex.h>
+#include <unotools/streamwrap.hxx>
#include <connectivity/CommonTools.hxx>
-#include <comphelper/numberedcollection.hxx>
+#include <connectivity/dbconversion.hxx>
#include <framework/titlehelper.hxx>
-#include <comphelper/property.hxx>
-#include <comphelper/propertysetinfo.hxx>
-#include <comphelper/genericpropertyset.hxx>
-#include <comphelper/mediadescriptor.hxx>
-#include <comphelper/namecontainer.hxx>
#include <connectivity/dbtools.hxx>
#include <com/sun/star/task/XStatusIndicator.hpp>
#include "Functions.hxx"
@@ -104,6 +111,8 @@
#include "Shape.hxx"
#include "ReportHelperImpl.hxx"
#include <svtools/itempool.hxx>
+#include <svtools/moduleoptions.hxx>
+#include <osl/thread.hxx>
#include <svx/paperinf.hxx>
#include <svx/svdlayer.hxx>
@@ -494,6 +503,75 @@ uno::Sequence< uno::Any > SAL_CALL OStyle::getPropertyDefaults( const uno::Seque
aRet[i] = getPropertyDefault(*pIter);
return aRet;
}
+namespace
+{
+ class FactoryLoader : public ::osl::Thread
+ {
+ ::rtl::OUString m_sMimeType;
+ uno::Reference< uno::XComponentContext > m_xContext;
+ public:
+ FactoryLoader(const ::rtl::OUString& _sMimeType,uno::Reference< uno::XComponentContext > const & _xContext)
+ :m_sMimeType(_sMimeType)
+ ,m_xContext(_xContext)
+ {}
+
+ protected:
+ virtual ~FactoryLoader(){}
+
+ /// Working method which should be overridden.
+ virtual void SAL_CALL run();
+ virtual void SAL_CALL onTerminated();
+ };
+
+ void SAL_CALL FactoryLoader::run()
+ {
+ try
+ {
+ uno::Reference<frame::XComponentLoader> xFrameLoad( m_xContext->getServiceManager()->createInstanceWithContext(
+ ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.frame.Desktop"))
+ ,m_xContext)
+ ,uno::UNO_QUERY);
+ ::rtl::OUString sTarget(RTL_CONSTASCII_USTRINGPARAM("_blank"));
+ sal_Int32 nFrameSearchFlag = frame::FrameSearchFlag::TASKS | frame::FrameSearchFlag::CREATE;
+ uno::Reference< frame::XFrame> xFrame = uno::Reference< frame::XFrame>(xFrameLoad,uno::UNO_QUERY)->findFrame(sTarget,nFrameSearchFlag);
+ xFrameLoad.set( xFrame,uno::UNO_QUERY);
+
+ if ( xFrameLoad.is() )
+ {
+ uno::Sequence < beans::PropertyValue > aArgs( 3);
+ sal_Int32 nLen = 0;
+ aArgs[nLen].Name = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("AsTemplate"));
+ aArgs[nLen++].Value <<= sal_False;
+
+ aArgs[nLen].Name = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ReadOnly"));
+ aArgs[nLen++].Value <<= sal_True;
+
+ aArgs[nLen].Name = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Hidden"));
+ aArgs[nLen++].Value <<= sal_True;
+
+ uno::Reference< lang::XMultiServiceFactory > xFac(m_xContext->getServiceManager(),uno::UNO_QUERY);
+ ::comphelper::MimeConfigurationHelper aHelper(xFac);
+ SvtModuleOptions aModuleOptions;
+ uno::Reference< frame::XModel > xModel(xFrameLoad->loadComponentFromURL(
+ aModuleOptions.GetFactoryEmptyDocumentURL( aModuleOptions.ClassifyFactoryByServiceName( aHelper.GetDocServiceNameFromMediaType(m_sMimeType) )),
+ ::rtl::OUString(), // empty frame name
+ 0,
+ aArgs
+ ),uno::UNO_QUERY);
+ ::comphelper::disposeComponent(xModel);
+ }
+ }
+ catch(uno::Exception& ex)
+ {
+ (void)ex;
+ OSL_ASSERT(0);
+ }
+ }
+ void SAL_CALL FactoryLoader::onTerminated()
+ {
+ delete this;
+ }
+}
// -----------------------------------------------------------------------------
struct OReportDefinitionImpl
{
@@ -555,6 +633,9 @@ struct OReportDefinitionImpl
,m_aDocEventListeners(_aMutex)
,m_sMimeType(MIMETYPE_OASIS_OPENDOCUMENT_TEXT)
,m_sIdentifier(SERVICE_REPORTDEFINITION)
+ // default visual area is 8 x 7 cm
+ ,m_aVisualAreaSize( 8000, 7000 )
+ ,m_nAspect(embed::Aspects::MSOLE_CONTENT)
,m_nGroupKeepTogether(0)
,m_nPageHeaderOption(0)
,m_nPageFooterOption(0)
@@ -672,6 +753,22 @@ void OReportDefinition::init()
{
try
{
+ static bool s_bFirstTime = sal_True;
+ if ( s_bFirstTime )
+ {
+ s_bFirstTime = false;
+ const uno::Sequence< ::rtl::OUString > aMimeTypes = getAvailableMimeTypes();
+ const ::rtl::OUString* pIter = aMimeTypes.getConstArray();
+ const ::rtl::OUString* pEnd = pIter + aMimeTypes.getLength();
+ for ( ; pIter != pEnd; ++pIter )
+ {
+ FactoryLoader* pCreatorThread = new FactoryLoader(*pIter,m_aProps->m_xContext);
+ pCreatorThread->createSuspended();
+ pCreatorThread->setPriority(osl_Thread_PriorityBelowNormal);
+ pCreatorThread->resume();
+ } // for ( ; pIter != pEnd; ++pIter )
+ }
+
m_pImpl->m_pReportModel.reset(new OReportModel(this));
m_pImpl->m_pReportModel->GetItemPool().FreezeIdRanges();
m_pImpl->m_pReportModel->SetScaleUnit( MAP_100TH_MM );
@@ -1491,6 +1588,24 @@ void SAL_CALL OReportDefinition::storeToStorage( const uno::Reference< embed::XS
bErr = sal_True;
sErrFile = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("content.xml"));
}
+ } // if ( !bErr )
+
+ uno::Any aImage;
+ uno::Reference< embed::XVisualObject > xCurrentController(getCurrentController(),uno::UNO_QUERY);
+ if ( xCurrentController.is() )
+ {
+ xCurrentController->setVisualAreaSize(m_pImpl->m_nAspect,m_pImpl->m_aVisualAreaSize);
+ aImage = xCurrentController->getPreferredVisualRepresentation( m_pImpl->m_nAspect ).Data;
+ }
+ if ( aImage.hasValue() )
+ {
+ ::rtl::OUString sObject1(RTL_CONSTASCII_USTRINGPARAM("report"));
+ ::rtl::OUString sPng(RTL_CONSTASCII_USTRINGPARAM("image/png"));
+
+ uno::Sequence<sal_Int8> aSeq;
+ aImage >>= aSeq;
+ uno::Reference<io::XInputStream> xStream = new ::comphelper::SequenceInputStream( aSeq );
+ m_pImpl->m_pObjectContainer->InsertGraphicStreamDirectly(xStream,sObject1,sPng);
}
if ( !bErr )
@@ -1788,23 +1903,44 @@ void SAL_CALL OReportDefinition::setVisualAreaSize( ::sal_Int64 _nAspect, const
{
::osl::MutexGuard aGuard(m_aMutex);
::connectivity::checkDisposed(ReportDefinitionBase::rBHelper.bDisposed);
- m_pImpl->m_aVisualAreaSize = _aSize;
+ //if( nAspect == embed::Aspects::MSOLE_CONTENT )
+ {
+ bool bChanged =
+ (m_pImpl->m_aVisualAreaSize.Width != _aSize.Width ||
+ m_pImpl->m_aVisualAreaSize.Height != _aSize.Height);
+ m_pImpl->m_aVisualAreaSize = _aSize;
+ if( bChanged )
+ setModified( sal_True );
+ }
m_pImpl->m_nAspect = _nAspect;
}
// -----------------------------------------------------------------------------
-awt::Size SAL_CALL OReportDefinition::getVisualAreaSize( ::sal_Int64 /*nAspect*/ ) throw (lang::IllegalArgumentException, embed::WrongStateException, uno::Exception, uno::RuntimeException)
+awt::Size SAL_CALL OReportDefinition::getVisualAreaSize( ::sal_Int64 /*_nAspect*/ ) throw (lang::IllegalArgumentException, embed::WrongStateException, uno::Exception, uno::RuntimeException)
{
::osl::MutexGuard aGuard(m_aMutex);
::connectivity::checkDisposed(ReportDefinitionBase::rBHelper.bDisposed);
return m_pImpl->m_aVisualAreaSize;
}
// -----------------------------------------------------------------------------
-embed::VisualRepresentation SAL_CALL OReportDefinition::getPreferredVisualRepresentation( ::sal_Int64 /*nAspect*/ ) throw (lang::IllegalArgumentException, embed::WrongStateException, uno::Exception, uno::RuntimeException)
+embed::VisualRepresentation SAL_CALL OReportDefinition::getPreferredVisualRepresentation( ::sal_Int64 /*_nAspect*/ ) throw (lang::IllegalArgumentException, embed::WrongStateException, uno::Exception, uno::RuntimeException)
{
::osl::MutexGuard aGuard(m_aMutex);
::connectivity::checkDisposed(ReportDefinitionBase::rBHelper.bDisposed);
- embed::VisualRepresentation aVisualRepresentation;
- return aVisualRepresentation;
+ embed::VisualRepresentation aResult;
+ ::rtl::OUString sImageName(RTL_CONSTASCII_USTRINGPARAM("report"));
+ ::rtl::OUString sMimeType;
+ uno::Reference<io::XInputStream> xStream = m_pImpl->m_pObjectContainer->GetGraphicStream(sImageName,&sMimeType);
+ if ( xStream.is() )
+ {
+ uno::Sequence<sal_Int8> aSeq;
+ xStream->readBytes(aSeq,xStream->available());
+ xStream->closeInput();
+ aResult.Data <<= aSeq;
+ aResult.Flavor.MimeType = sMimeType;
+ aResult.Flavor.DataType = ::getCppuType( &aSeq );
+ }
+
+ return aResult;
}
// -----------------------------------------------------------------------------
::sal_Int32 SAL_CALL OReportDefinition::getMapUnit( ::sal_Int64 /*nAspect*/ ) throw (uno::Exception, uno::RuntimeException)
@@ -1829,6 +1965,9 @@ void SAL_CALL OReportDefinition::setModified( ::sal_Bool _bModified ) throw (bea
if ( m_pImpl->m_bModified != _bModified )
{
m_pImpl->m_bModified = _bModified;
+ if ( m_pImpl->m_pReportModel->IsChanged() != _bModified )
+ m_pImpl->m_pReportModel->SetChanged(_bModified);
+
lang::EventObject aEvent(*this);
aGuard.clear();
m_pImpl->m_aModifyListeners.notifyEach(&util::XModifyListener::modified,aEvent);
@@ -2205,6 +2344,9 @@ uno::Reference< uno::XInterface > SAL_CALL OReportDefinition::createInstance( co
{
uno::Reference<chart2::data::XDatabaseDataProvider> xDataProvider(chart2::data::DatabaseDataProvider::createWithConnection( m_aProps->m_xContext, m_pImpl->m_xActiveConnection ));
xDataProvider->setRowLimit(10);
+ uno::Reference< container::XChild > xChild(xDataProvider,uno::UNO_QUERY);
+ if ( xChild.is() )
+ xChild->setParent(*this);
return uno::Reference< uno::XInterface >(xDataProvider,uno::UNO_QUERY);
}
else if ( aServiceSpecifier.reverseCompareToAsciiL( RTL_CONSTASCII_STRINGPARAM("com.sun.star.xml.NamespaceMap")) == 0 )
@@ -2318,36 +2460,28 @@ class OStylesHelper : public ::cppu::BaseMutex, public TStylesBASE
OStylesHelper(const OStylesHelper&);
void operator =(const OStylesHelper&);
protected:
- // TODO: VirtualFunctionFinder: This is virtual function!
- //
virtual ~OStylesHelper(){}
public:
OStylesHelper(const uno::Type _aType = ::getCppuType(static_cast< uno::Reference< container::XElementAccess >* >(NULL)));
// XNameContainer
- // TODO: VirtualFunctionFinder: This is virtual function!
- //
virtual void SAL_CALL insertByName( const ::rtl::OUString& aName, const uno::Any& aElement ) throw(lang::IllegalArgumentException, container::ElementExistException,lang::WrappedTargetException, uno::RuntimeException);
- // TODO: VirtualFunctionFinder: This is virtual function!
- //
virtual void SAL_CALL removeByName( const ::rtl::OUString& Name ) throw(container::NoSuchElementException, lang::WrappedTargetException,uno::RuntimeException);
// XNameReplace
- // TODO: VirtualFunctionFinder: This is virtual function!
- //
virtual void SAL_CALL replaceByName( const ::rtl::OUString& aName, const uno::Any& aElement ) throw(lang::IllegalArgumentException, container::NoSuchElementException,lang::WrappedTargetException, uno::RuntimeException);
// container::XElementAccess
- uno::Type SAL_CALL getElementType( ) throw(uno::RuntimeException);
- sal_Bool SAL_CALL hasElements( ) throw(uno::RuntimeException);
+ virtual uno::Type SAL_CALL getElementType( ) throw(uno::RuntimeException);
+ virtual sal_Bool SAL_CALL hasElements( ) throw(uno::RuntimeException);
// container::XIndexAccess
- sal_Int32 SAL_CALL getCount( ) throw(uno::RuntimeException);
- uno::Any SAL_CALL getByIndex( sal_Int32 Index ) throw(lang::IndexOutOfBoundsException, lang::WrappedTargetException, uno::RuntimeException);
+ virtual sal_Int32 SAL_CALL getCount( ) throw(uno::RuntimeException);
+ virtual uno::Any SAL_CALL getByIndex( sal_Int32 Index ) throw(lang::IndexOutOfBoundsException, lang::WrappedTargetException, uno::RuntimeException);
- // container::XNameAccess
- uno::Any SAL_CALL getByName( const ::rtl::OUString& aName ) throw(container::NoSuchElementException, lang::WrappedTargetException, uno::RuntimeException);
- uno::Sequence< ::rtl::OUString > SAL_CALL getElementNames( ) throw(uno::RuntimeException);
- sal_Bool SAL_CALL hasByName( const ::rtl::OUString& aName ) throw(uno::RuntimeException);
+ // container::XNameAccess
+ virtual uno::Any SAL_CALL getByName( const ::rtl::OUString& aName ) throw(container::NoSuchElementException, lang::WrappedTargetException, uno::RuntimeException);
+ virtual uno::Sequence< ::rtl::OUString > SAL_CALL getElementNames( ) throw(uno::RuntimeException);
+ virtual sal_Bool SAL_CALL hasByName( const ::rtl::OUString& aName ) throw(uno::RuntimeException);
};
OStylesHelper::OStylesHelper(const uno::Type _aType)
@@ -2411,8 +2545,6 @@ sal_Bool SAL_CALL OStylesHelper::hasByName( const ::rtl::OUString& aName ) throw
::osl::MutexGuard aGuard(m_aMutex);
return m_aElements.find(aName) != m_aElements.end();
}
-// TODO: VirtualFunctionFinder: This is virtual function!
-//
// -----------------------------------------------------------------------------
// XNameContainer
void SAL_CALL OStylesHelper::insertByName( const ::rtl::OUString& aName, const uno::Any& aElement ) throw(lang::IllegalArgumentException, container::ElementExistException,lang::WrappedTargetException, uno::RuntimeException)
@@ -2425,8 +2557,6 @@ void SAL_CALL OStylesHelper::insertByName( const ::rtl::OUString& aName, const u
throw lang::IllegalArgumentException();
m_aElementsPos.push_back(m_aElements.insert(TStyleElements::value_type(aName,aElement)).first);
- // TODO: VirtualFunctionFinder: This is virtual function!
- //
}
// -----------------------------------------------------------------------------
void SAL_CALL OStylesHelper::removeByName( const ::rtl::OUString& aName ) throw(container::NoSuchElementException, lang::WrappedTargetException,uno::RuntimeException)
@@ -2438,8 +2568,6 @@ void SAL_CALL OStylesHelper::removeByName( const ::rtl::OUString& aName ) throw(
m_aElementsPos.erase(::std::find(m_aElementsPos.begin(),m_aElementsPos.end(),aFind));
m_aElements.erase(aFind);
}
-// TODO: VirtualFunctionFinder: This is virtual function!
-//
// -----------------------------------------------------------------------------
// XNameReplace
void SAL_CALL OStylesHelper::replaceByName( const ::rtl::OUString& aName, const uno::Any& aElement ) throw(lang::IllegalArgumentException, container::NoSuchElementException,lang::WrappedTargetException, uno::RuntimeException)
@@ -2723,6 +2851,47 @@ uno::Reference< uno::XComponentContext > OReportDefinition::getContext() const
{
return m_aProps->m_xContext;
}
+// -----------------------------------------------------------------------------
+uno::Any SAL_CALL OReportDefinition::getTransferData( const datatransfer::DataFlavor& aFlavor ) throw (datatransfer::UnsupportedFlavorException, io::IOException, uno::RuntimeException)
+{
+ uno::Any aResult;
+ if( isDataFlavorSupported( aFlavor ) )
+ {
+ try
+ {
+ aResult <<= getPreferredVisualRepresentation(0).Data;
+ }
+ catch( uno::Exception & ex )
+ {
+ DBG_UNHANDLED_EXCEPTION();
+ (void)ex;
+ }
+ }
+ else
+ {
+ throw datatransfer::UnsupportedFlavorException(aFlavor.MimeType, static_cast< ::cppu::OWeakObject* >( this ));
+ }
+
+ return aResult;
+}
+// -----------------------------------------------------------------------------
+uno::Sequence< datatransfer::DataFlavor > SAL_CALL OReportDefinition::getTransferDataFlavors( ) throw (uno::RuntimeException)
+{
+ uno::Sequence< datatransfer::DataFlavor > aRet(1);
+
+ aRet[0] = datatransfer::DataFlavor( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("image/png")),
+ ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("PNG")),
+ ::getCppuType( (const uno::Sequence< sal_Int8 >*) NULL ) );
+
+ return aRet;
+}
+// -----------------------------------------------------------------------------
+::sal_Bool SAL_CALL OReportDefinition::isDataFlavorSupported( const datatransfer::DataFlavor& aFlavor ) throw (uno::RuntimeException)
+{
+ return aFlavor.MimeType.equals(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("image/png")));
+}
+// -----------------------------------------------------------------------------
+// -----------------------------------------------------------------------------
// =============================================================================
}// namespace reportdesign
// =============================================================================
diff --git a/reportdesign/source/core/api/ReportEngineJFree.cxx b/reportdesign/source/core/api/ReportEngineJFree.cxx
index e17bd9d2f11a..03c5307e8f25 100644
--- a/reportdesign/source/core/api/ReportEngineJFree.cxx
+++ b/reportdesign/source/core/api/ReportEngineJFree.cxx
@@ -33,9 +33,11 @@
#include <comphelper/documentconstants.hxx>
#include <comphelper/storagehelper.hxx>
#include <connectivity/dbtools.hxx>
+#include <comphelper/sequence.hxx>
+#include <comphelper/mimeconfighelper.hxx>
+#include <comphelper/property.hxx>
#include <com/sun/star/beans/PropertyAttribute.hpp>
#include <com/sun/star/beans/NamedValue.hpp>
-#include <comphelper/sequence.hxx>
#include <com/sun/star/frame/XComponentLoader.hpp>
#include <com/sun/star/frame/FrameSearchFlag.hpp>
#include <com/sun/star/embed/XTransactedObject.hpp>
@@ -46,16 +48,18 @@
#include <com/sun/star/task/XInteractionHandler.hpp>
#include <com/sun/star/task/XJob.hpp>
-#ifndef REPORTDESIGN_SHARED_CORESTRINGS_HRC
-#include "corestrings.hrc"
-#endif
+
#include <tools/debug.hxx>
+#include <tools/urlobj.hxx>
#include <svtools/useroptions.hxx>
#include <unotools/tempfile.hxx>
#include <unotools/sharedunocomponent.hxx>
-#include <comphelper/mimeconfighelper.hxx>
+
#include "Tools.hxx"
-#include <comphelper/property.hxx>
+#include "corestrings.hrc"
+#include "core_resource.hrc"
+#include "core_resource.hxx"
+
#include <connectivity/CommonTools.hxx>
#include <rtl/ustrbuf.hxx>
#include <sfx2/docfilt.hxx>
@@ -72,6 +76,7 @@ OReportEngineJFree::OReportEngineJFree( const uno::Reference< uno::XComponentCon
:ReportEngineBase(m_aMutex)
,ReportEnginePropertySet(context,static_cast< Implements >(IMPLEMENTS_PROPERTY_SET),uno::Sequence< ::rtl::OUString >())
,m_xContext(context)
+,m_nMaxRows(0)
{
DBG_CTOR( rpt_OReportEngineJFree,NULL);
}
@@ -197,18 +202,29 @@ void SAL_CALL OReportEngineJFree::setStatusIndicator( const uno::Reference< task
}
m_xReport->storeToStorage(xTemp,aEmpty); // store to temp file because it may contain information which aren't in the database yet.
- uno::Sequence< beans::NamedValue > aConvertedProperties(7);
+ uno::Sequence< beans::NamedValue > aConvertedProperties(8);
sal_Int32 nPos = 0;
aConvertedProperties[nPos].Name = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("InputStorage"));
aConvertedProperties[nPos++].Value <<= xTemp;
aConvertedProperties[nPos].Name = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("OutputStorage"));
-
+ ::rtl::OUString sFileURL;
String sName = m_xReport->getCaption();
if ( !sName.Len() )
sName = m_xReport->getName();
- ::utl::TempFile aFile(sName,sal_False,&sExt);
- uno::Reference< embed::XStorage > xOut = OStorageHelper::GetStorageFromURL(aFile.GetURL(),embed::ElementModes::WRITE | embed::ElementModes::TRUNCATE,uno::Reference< lang::XMultiServiceFactory >(m_xContext->getServiceManager(),uno::UNO_QUERY));
+ {
+ ::utl::TempFile aTestFile(sName,sal_False,&sExt);
+ if ( !aTestFile.IsValid() )
+ {
+ sName = RPT_RESSTRING(RID_STR_REPORT,m_xContext->getServiceManager());
+ ::utl::TempFile aFile(sName,sal_False,&sExt);
+ sFileURL = aFile.GetURL();
+ }
+ else
+ sFileURL = aTestFile.GetURL();
+ }
+
+ uno::Reference< embed::XStorage > xOut = OStorageHelper::GetStorageFromURL(sFileURL,embed::ElementModes::WRITE | embed::ElementModes::TRUNCATE,uno::Reference< lang::XMultiServiceFactory >(m_xContext->getServiceManager(),uno::UNO_QUERY));
utl::DisposableComponent aOut(xOut);
xStorageProp.set(xOut,uno::UNO_QUERY);
if ( xStorageProp.is() )
@@ -224,6 +240,9 @@ void SAL_CALL OReportEngineJFree::setStatusIndicator( const uno::Reference< task
aConvertedProperties[nPos].Name = PROPERTY_ACTIVECONNECTION;
aConvertedProperties[nPos++].Value <<= m_xActiveConnection;
+ aConvertedProperties[nPos].Name = PROPERTY_MAXROWS;
+ aConvertedProperties[nPos++].Value <<= m_nMaxRows;
+
// some meta data
SvtUserOptions aUserOpts;
::rtl::OUStringBuffer sAuthor(aUserOpts.GetFirstName());
@@ -246,7 +265,7 @@ void SAL_CALL OReportEngineJFree::setStatusIndicator( const uno::Reference< task
if ( xStorageProp.is() )
{
//xStorageProp->getPropertyValue(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("URL"))) >>= sOutputName;
- sOutputName = aFile.GetURL();
+ sOutputName = sFileURL;
}
}
@@ -293,7 +312,7 @@ uno::Reference< frame::XModel > SAL_CALL OReportEngineJFree::createDocumentAlive
::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.frame.Desktop"))
,m_xContext)
,uno::UNO_QUERY);
- ::rtl::OUString sTarget = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("_blank"));
+ ::rtl::OUString sTarget(RTL_CONSTASCII_USTRINGPARAM("_blank"));
sal_Int32 nFrameSearchFlag = frame::FrameSearchFlag::TASKS | frame::FrameSearchFlag::CREATE;
uno::Reference< frame::XFrame> xFrame = uno::Reference< frame::XFrame>(xFrameLoad,uno::UNO_QUERY)->findFrame(sTarget,nFrameSearchFlag);
xFrameLoad.set( xFrame,uno::UNO_QUERY);
@@ -316,7 +335,7 @@ uno::Reference< frame::XModel > SAL_CALL OReportEngineJFree::createDocumentAlive
}
uno::Reference< lang::XMultiServiceFactory > xFac(m_xContext->getServiceManager(),uno::UNO_QUERY);
- ::comphelper::MimeConfigurationHelper aHelper(xFac);
+ /*::comphelper::MimeConfigurationHelper aHelper(xFac);*/
xModel.set( xFrameLoad->loadComponentFromURL(
sOutputName,
::rtl::OUString(), // empty frame name
@@ -394,6 +413,17 @@ void SAL_CALL OReportEngineJFree::setActiveConnection( const uno::Reference< sdb
throw lang::IllegalArgumentException();
set(PROPERTY_ACTIVECONNECTION,_activeconnection,m_xActiveConnection);
}
+// -----------------------------------------------------------------------------
+::sal_Int32 SAL_CALL OReportEngineJFree::getMaxRows() throw (uno::RuntimeException)
+{
+ ::osl::MutexGuard aGuard(m_aMutex);
+ return m_nMaxRows;
+}
+// -----------------------------------------------------------------------------
+void SAL_CALL OReportEngineJFree::setMaxRows( ::sal_Int32 _MaxRows ) throw (uno::RuntimeException)
+{
+ set(PROPERTY_MAXROWS,_MaxRows,m_nMaxRows);
+}
// =============================================================================
} // namespace reportdesign
// =============================================================================
diff --git a/reportdesign/source/core/inc/ReportControlModel.hxx b/reportdesign/source/core/inc/ReportControlModel.hxx
index 2e0bd0bff730..a11dd61e8ed6 100644
--- a/reportdesign/source/core/inc/ReportControlModel.hxx
+++ b/reportdesign/source/core/inc/ReportControlModel.hxx
@@ -74,7 +74,7 @@ namespace reportdesign
::rtl::OUString sHyperLinkName;
::rtl::OUString sVisitedCharStyleName;
::rtl::OUString sUnvisitedCharStyleName;
- short aVerticalAlignment;
+ com::sun::star::style::VerticalAlignment aVerticalAlignment;
::sal_Int16 nCharEscapement;
::sal_Int16 nCharCaseMap;
::sal_Int16 nCharKerning;
diff --git a/reportdesign/source/core/inc/ReportEngineJFree.hxx b/reportdesign/source/core/inc/ReportEngineJFree.hxx
index c65a1ee7b7ae..9e95c0c2c593 100644
--- a/reportdesign/source/core/inc/ReportEngineJFree.hxx
+++ b/reportdesign/source/core/inc/ReportEngineJFree.hxx
@@ -57,6 +57,7 @@ namespace reportdesign
::com::sun::star::uno::Reference< ::com::sun::star::report::XReportDefinition > m_xReport;
::com::sun::star::uno::Reference< ::com::sun::star::task::XStatusIndicator> m_StatusIndicator;
::com::sun::star::uno::Reference< ::com::sun::star::sdbc::XConnection > m_xActiveConnection;
+ ::sal_Int32 m_nMaxRows;
private:
OReportEngineJFree(const OReportEngineJFree&);
OReportEngineJFree& operator=(const OReportEngineJFree&);
@@ -116,6 +117,8 @@ namespace reportdesign
virtual void SAL_CALL setActiveConnection( const ::com::sun::star::uno::Reference< ::com::sun::star::sdbc::XConnection >& _activeconnection ) throw (::com::sun::star::lang::IllegalArgumentException, ::com::sun::star::uno::RuntimeException);
virtual ::com::sun::star::uno::Reference< ::com::sun::star::task::XStatusIndicator > SAL_CALL getStatusIndicator() throw (::com::sun::star::uno::RuntimeException) ;
virtual void SAL_CALL setStatusIndicator( const ::com::sun::star::uno::Reference< ::com::sun::star::task::XStatusIndicator >& _statusindicator ) throw (::com::sun::star::uno::RuntimeException) ;
+ virtual ::sal_Int32 SAL_CALL getMaxRows() throw (::com::sun::star::uno::RuntimeException);
+ virtual void SAL_CALL setMaxRows( ::sal_Int32 _MaxRows ) throw (::com::sun::star::uno::RuntimeException);
// Methods
virtual ::com::sun::star::uno::Reference< ::com::sun::star::frame::XModel > SAL_CALL createDocumentModel( ) throw (::com::sun::star::lang::DisposedException, ::com::sun::star::lang::IllegalArgumentException, ::com::sun::star::uno::Exception, ::com::sun::star::uno::RuntimeException) ;
virtual ::com::sun::star::uno::Reference< ::com::sun::star::frame::XModel > SAL_CALL createDocumentAlive( const ::com::sun::star::uno::Reference< ::com::sun::star::frame::XFrame >& _frame ) throw (::com::sun::star::lang::DisposedException, ::com::sun::star::lang::IllegalArgumentException, ::com::sun::star::uno::Exception, ::com::sun::star::uno::RuntimeException) ;
diff --git a/reportdesign/source/core/inc/ReportHelperImpl.hxx b/reportdesign/source/core/inc/ReportHelperImpl.hxx
index 14e9bc02b801..ebf8c566133d 100644
--- a/reportdesign/source/core/inc/ReportHelperImpl.hxx
+++ b/reportdesign/source/core/inc/ReportHelperImpl.hxx
@@ -234,13 +234,13 @@ void SAL_CALL clazz::setCharScaleWidth(::sal_Int16 the_value) throw (uno::Runtim
float newValue = the_value; \
set(PROPERTY_CHARSCALEWIDTH,newValue,varName.aFontDescriptor.CharacterWidth); \
} \
-::sal_Int16 SAL_CALL clazz::getParaAdjust() throw (beans::UnknownPropertyException,uno::RuntimeException) \
+sal_Int16 SAL_CALL clazz::getParaAdjust() throw (beans::UnknownPropertyException,uno::RuntimeException) \
{ \
::osl::MutexGuard aGuard(m_aMutex); \
return varName.nAlign; \
} \
\
-void SAL_CALL clazz::setParaAdjust( ::sal_Int16 _align ) throw (beans::UnknownPropertyException,uno::RuntimeException) \
+void SAL_CALL clazz::setParaAdjust( sal_Int16 _align ) throw (beans::UnknownPropertyException,uno::RuntimeException) \
{ \
set(PROPERTY_PARAADJUST,_align,varName.nAlign); \
} \
@@ -320,16 +320,14 @@ void SAL_CALL clazz::setCharUnderlineColor( ::sal_Int32 _textlinecolor ) throw (
set(PROPERTY_CHARUNDERLINECOLOR,_textlinecolor,varName.nTextLineColor); \
} \
\
-short SAL_CALL clazz::getParaVertAlignment() throw (uno::RuntimeException) \
+style::VerticalAlignment SAL_CALL clazz::getVerticalAlign() throw (beans::UnknownPropertyException,uno::RuntimeException) \
{ \
::osl::MutexGuard aGuard(m_aMutex); \
return varName.aVerticalAlignment; \
} \
\
-void SAL_CALL clazz::setParaVertAlignment( short _verticalalign ) throw (lang::IllegalArgumentException,uno::RuntimeException) \
+void SAL_CALL clazz::setVerticalAlign( style::VerticalAlignment _verticalalign ) throw (lang::IllegalArgumentException,beans::UnknownPropertyException,uno::RuntimeException) \
{ \
- if ( _verticalalign < text::ParagraphVertAlign::AUTOMATIC || _verticalalign > text::ParagraphVertAlign::BOTTOM ) \
- throw lang::IllegalArgumentException(); \
set(PROPERTY_VERTICALALIGN,_verticalalign,varName.aVerticalAlignment); \
} \
\
@@ -801,11 +799,11 @@ void SAL_CALL clazz::setCharLocaleComplex( const ::com::sun::star::lang::Locale&
#define NO_REPORTCONTROLFORMAT_IMPL(clazz) \
-::sal_Int16 SAL_CALL clazz::getParaAdjust() throw (uno::RuntimeException, beans::UnknownPropertyException)\
+sal_Int16 SAL_CALL clazz::getParaAdjust() throw (uno::RuntimeException, beans::UnknownPropertyException)\
{\
throw beans::UnknownPropertyException();\
}\
-void SAL_CALL clazz::setParaAdjust(::sal_Int16 /*the_value*/) throw (uno::RuntimeException, beans::UnknownPropertyException)\
+void SAL_CALL clazz::setParaAdjust(sal_Int16 /*the_value*/) throw (uno::RuntimeException, beans::UnknownPropertyException)\
{\
throw beans::UnknownPropertyException();\
}\
@@ -1030,16 +1028,14 @@ void SAL_CALL clazz::setCharUnderlineColor( ::sal_Int32 /*_textlinecolor*/ ) thr
throw beans::UnknownPropertyException();\
}\
\
-short SAL_CALL clazz::getParaVertAlignment() throw (uno::RuntimeException)\
+style::VerticalAlignment SAL_CALL clazz::getVerticalAlign() throw (beans::UnknownPropertyException,uno::RuntimeException)\
{\
::osl::MutexGuard aGuard(m_aMutex);\
return m_aProps.aFormatProperties.aVerticalAlignment;\
}\
\
-void SAL_CALL clazz::setParaVertAlignment( short _verticalalign ) throw (lang::IllegalArgumentException,uno::RuntimeException)\
+void SAL_CALL clazz::setVerticalAlign( style::VerticalAlignment _verticalalign ) throw (lang::IllegalArgumentException,beans::UnknownPropertyException,uno::RuntimeException)\
{\
- if ( _verticalalign < text::ParagraphVertAlign::AUTOMATIC || _verticalalign > text::ParagraphVertAlign::BOTTOM )\
- throw lang::IllegalArgumentException();\
set(PROPERTY_VERTICALALIGN,_verticalalign,m_aProps.aFormatProperties.aVerticalAlignment);\
}\
\
diff --git a/reportdesign/source/core/inc/Tools.hxx b/reportdesign/source/core/inc/Tools.hxx
index f549582019b2..232408c308fb 100644
--- a/reportdesign/source/core/inc/Tools.hxx
+++ b/reportdesign/source/core/inc/Tools.hxx
@@ -103,9 +103,12 @@ namespace reportdesign
if ( _pShape->m_aProps.aComponent.m_xShape.is() )
{
::com::sun::star::awt::Size aOldSize = _pShape->m_aProps.aComponent.m_xShape->getSize();
- _pShape->m_aProps.aComponent.m_nWidth = aOldSize.Width;
- _pShape->m_aProps.aComponent.m_nHeight = aOldSize.Height;
- _pShape->m_aProps.aComponent.m_xShape->setSize(aSize);
+ if ( aOldSize.Height != aSize.Height || aOldSize.Width != aSize.Width )
+ {
+ _pShape->m_aProps.aComponent.m_nWidth = aOldSize.Width;
+ _pShape->m_aProps.aComponent.m_nHeight = aOldSize.Height;
+ _pShape->m_aProps.aComponent.m_xShape->setSize(aSize);
+ }
}
_pShape->set(PROPERTY_WIDTH,aSize.Width,_pShape->m_aProps.aComponent.m_nWidth);
_pShape->set(PROPERTY_HEIGHT,aSize.Height,_pShape->m_aProps.aComponent.m_nHeight);
@@ -136,9 +139,12 @@ namespace reportdesign
if ( _pShape->m_aProps.aComponent.m_xShape.is() )
{
aOldPos = _pShape->m_aProps.aComponent.m_xShape->getPosition();
- _pShape->m_aProps.aComponent.m_nPosX = aOldPos.X;
- _pShape->m_aProps.aComponent.m_nPosY = aOldPos.Y;
- _pShape->m_aProps.aComponent.m_xShape->setPosition(aPosition);
+ if ( aOldPos.X != aPosition.X || aOldPos.Y != aPosition.Y )
+ {
+ _pShape->m_aProps.aComponent.m_nPosX = aOldPos.X;
+ _pShape->m_aProps.aComponent.m_nPosY = aOldPos.Y;
+ _pShape->m_aProps.aComponent.m_xShape->setPosition(aPosition);
+ }
}
_pShape->set(PROPERTY_POSITIONX,aPosition.X,aOldPos.X);
_pShape->set(PROPERTY_POSITIONY,aPosition.Y,aOldPos.Y);
diff --git a/reportdesign/source/core/sdr/PropertyForward.cxx b/reportdesign/source/core/sdr/PropertyForward.cxx
index f5ec06d1e683..7f71d101e91b 100644
--- a/reportdesign/source/core/sdr/PropertyForward.cxx
+++ b/reportdesign/source/core/sdr/PropertyForward.cxx
@@ -33,6 +33,7 @@
#include <comphelper/property.hxx>
#include <com/sun/star/sdbcx/XAppend.hpp>
#include <tools/debug.hxx>
+#include <tools/diagnose_ex.h>
#include "corestrings.hrc"
//........................................................................
@@ -71,12 +72,12 @@ OPropertyMediator::OPropertyMediator(const Reference< XPropertySet>& _xSource
TPropertyNamePair::iterator aEnd = m_aNameMap.end();
for (; aIter != aEnd; ++aIter)
{
- Any aValue = _xDest->getPropertyValue(aIter->second);
Property aProp = m_xSourceInfo->getPropertyByName(aIter->first);
if (0 == (aProp.Attributes & PropertyAttribute::READONLY))
{
+ Any aValue = _xDest->getPropertyValue(aIter->second.first);
if ( 0 != (aProp.Attributes & PropertyAttribute::MAYBEVOID) || aValue.hasValue() )
- _xSource->setPropertyValue(aIter->first,aValue);
+ _xSource->setPropertyValue(aIter->first,aIter->second.second->operator()(aIter->second.first,aValue));
}
}
}
@@ -86,13 +87,14 @@ OPropertyMediator::OPropertyMediator(const Reference< XPropertySet>& _xSource
TPropertyNamePair::iterator aIter = m_aNameMap.begin();
TPropertyNamePair::iterator aEnd = m_aNameMap.end();
for (; aIter != aEnd; ++aIter)
- _xDest->setPropertyValue(aIter->second,_xSource->getPropertyValue(aIter->first));
+ _xDest->setPropertyValue(aIter->second.first,aIter->second.second->operator()(aIter->second.first,_xSource->getPropertyValue(aIter->first)));
}
startListening();
}
- catch(Exception&)
+ catch(Exception& e)
{
- OSL_ENSURE(sal_False, "OPropertyMediator::OPropertyMediator: caught an exception!");
+ DBG_UNHANDLED_EXCEPTION();
+ (void)e;
}
} // if ( m_xDest.is() && m_xSource.is() )
osl_decrementInterlockedCount(&m_refCount);
@@ -125,7 +127,7 @@ void SAL_CALL OPropertyMediator::propertyChange( const PropertyChangeEvent& evt
TPropertyNamePair::iterator aFind = m_aNameMap.find(evt.PropertyName);
::rtl::OUString sPropName;
if ( aFind != m_aNameMap.end() )
- sPropName = aFind->second;
+ sPropName = aFind->second.first;
else
{
aFind = ::std::find_if(
@@ -133,14 +135,14 @@ void SAL_CALL OPropertyMediator::propertyChange( const PropertyChangeEvent& evt
m_aNameMap.end(),
::std::compose1(
::std::bind2nd(::std::equal_to< ::rtl::OUString >(), evt.PropertyName),
- ::std::select2nd<TPropertyNamePair::value_type>()
+ ::std::compose1(::std::select1st<TPropertyConverter>(),::std::select2nd<TPropertyNamePair::value_type>())
)
);
if ( aFind != m_aNameMap.end() )
sPropName = aFind->first;
}
if ( sPropName.getLength() && xPropInfo->hasPropertyByName(sPropName) )
- xProp->setPropertyValue(sPropName,evt.NewValue);
+ xProp->setPropertyValue(sPropName,aFind->second.second->operator()(sPropName,evt.NewValue));
else if ( evt.PropertyName == PROPERTY_CHARFONTNAME
|| evt.PropertyName == PROPERTY_CHARFONTSTYLENAME
|| evt.PropertyName == PROPERTY_CHARSTRIKEOUT
diff --git a/reportdesign/source/core/sdr/RptObject.cxx b/reportdesign/source/core/sdr/RptObject.cxx
index b5974a226341..3036872518b6 100644
--- a/reportdesign/source/core/sdr/RptObject.cxx
+++ b/reportdesign/source/core/sdr/RptObject.cxx
@@ -56,6 +56,7 @@
#include <com/sun/star/awt/XUnoControlContainer.hpp>
#include <com/sun/star/awt/XVclContainerPeer.hpp>
#include <com/sun/star/awt/XWindow.hpp>
+#include <com/sun/star/awt/TextAlign.hpp>
#include <com/sun/star/beans/XPropertySet.hpp>
#include <com/sun/star/beans/PropertyAttribute.hpp>
#include <com/sun/star/script/XScriptEventsSupplier.hpp>
@@ -67,6 +68,8 @@
#include <com/sun/star/chart2/data/XDataReceiver.hpp>
#include <com/sun/star/chart2/data/DatabaseDataProvider.hpp>
#include <com/sun/star/chart2/XChartDocument.hpp>
+#include <com/sun/star/style/VerticalAlignment.hpp>
+#include <com/sun/star/style/ParagraphAdjust.hpp>
#include <com/sun/star/report/XFormattedField.hpp>
#include <comphelper/genericpropertyset.hxx>
#include <comphelper/processfactory.hxx>
@@ -74,6 +77,7 @@
#include <tools/diagnose_ex.h>
#include "PropertyForward.hxx"
#include <connectivity/dbtools.hxx>
+#include <connectivity/dbconversion.hxx>
#include "UndoActions.hxx"
#include "UndoEnv.hxx"
#include <algorithm>
@@ -179,6 +183,63 @@ SdrObject* OObjectBase::createObject(const uno::Reference< report::XReportCompon
return pNewObj;
}
// -----------------------------------------------------------------------------
+namespace
+{
+ class ParaAdjust : public AnyConverter
+ {
+ public:
+ virtual ::com::sun::star::uno::Any operator() (const ::rtl::OUString& _sPropertyName,const ::com::sun::star::uno::Any& lhs) const
+ {
+ uno::Any aRet;
+ if ( _sPropertyName.equalsAscii(PROPERTY_PARAADJUST) )
+ {
+ sal_Int16 nTextAlign = 0;
+ lhs >>= nTextAlign;
+ switch(nTextAlign)
+ {
+ case awt::TextAlign::LEFT:
+ nTextAlign = style::ParagraphAdjust_LEFT;
+ break;
+ case awt::TextAlign::CENTER:
+ nTextAlign = style::ParagraphAdjust_CENTER;
+ break;
+ case awt::TextAlign::RIGHT:
+ nTextAlign = style::ParagraphAdjust_RIGHT;
+ break;
+ default:
+ OSL_ENSURE(0,"Illegal text alignment value!");
+ break;
+ } // switch(nTextAlign)
+ aRet <<= (style::ParagraphAdjust)nTextAlign;
+ }
+ else
+ {
+ sal_Int16 nTextAlign = 0;
+ sal_Int16 eParagraphAdjust = 0;
+ lhs >>= eParagraphAdjust;
+ switch(eParagraphAdjust)
+ {
+ case style::ParagraphAdjust_LEFT:
+ case style::ParagraphAdjust_BLOCK:
+ nTextAlign = awt::TextAlign::LEFT;
+ break;
+ case style::ParagraphAdjust_CENTER:
+ nTextAlign = awt::TextAlign::CENTER;
+ break;
+ case style::ParagraphAdjust_RIGHT:
+ nTextAlign = awt::TextAlign::RIGHT;
+ break;
+ default:
+ OSL_ENSURE(0,"Illegal text alignment value!");
+ break;
+ } // switch(eParagraphAdjust)
+ aRet <<= nTextAlign;
+ }
+ return aRet;
+ }
+ };
+}
+// -----------------------------------------------------------------------------
const TPropertyNamePair& getPropertyNameMap(sal_uInt16 _nObjectId)
{
switch(_nObjectId)
@@ -188,30 +249,54 @@ const TPropertyNamePair& getPropertyNameMap(sal_uInt16 _nObjectId)
static TPropertyNamePair s_aNameMap;
if ( s_aNameMap.empty() )
{
- s_aNameMap.insert(TPropertyNamePair::value_type(PROPERTY_CONTROLBACKGROUND,PROPERTY_BACKGROUNDCOLOR));
- s_aNameMap.insert(TPropertyNamePair::value_type(PROPERTY_CONTROLBORDER,PROPERTY_BORDER));
- s_aNameMap.insert(TPropertyNamePair::value_type(PROPERTY_CONTROLBORDERCOLOR,PROPERTY_BORDERCOLOR));
+ ::boost::shared_ptr<AnyConverter> aNoConverter(new AnyConverter());
+ s_aNameMap.insert(TPropertyNamePair::value_type(PROPERTY_CONTROLBACKGROUND,TPropertyConverter(PROPERTY_BACKGROUNDCOLOR,aNoConverter)));
+ s_aNameMap.insert(TPropertyNamePair::value_type(PROPERTY_CONTROLBORDER,TPropertyConverter(PROPERTY_BORDER,aNoConverter)));
+ s_aNameMap.insert(TPropertyNamePair::value_type(PROPERTY_CONTROLBORDERCOLOR,TPropertyConverter(PROPERTY_BORDERCOLOR,aNoConverter)));
//s_aNameMap.insert(TPropertyNamePair::value_type(PROPERTY_PARAADJUST,PROPERTY_ALIGN));
}
return s_aNameMap;
}
case OBJ_DLG_FIXEDTEXT:
+ {
+ static TPropertyNamePair s_aNameMap;
+ if ( s_aNameMap.empty() )
+ {
+ ::boost::shared_ptr<AnyConverter> aNoConverter(new AnyConverter());
+ s_aNameMap.insert(TPropertyNamePair::value_type(PROPERTY_CHARCOLOR,TPropertyConverter(PROPERTY_TEXTCOLOR,aNoConverter)));
+ s_aNameMap.insert(TPropertyNamePair::value_type(PROPERTY_CONTROLBACKGROUND,TPropertyConverter(PROPERTY_BACKGROUNDCOLOR,aNoConverter)));
+ s_aNameMap.insert(TPropertyNamePair::value_type(PROPERTY_CHARUNDERLINECOLOR,TPropertyConverter(PROPERTY_TEXTLINECOLOR,aNoConverter)));
+ s_aNameMap.insert(TPropertyNamePair::value_type(PROPERTY_CHARRELIEF,TPropertyConverter(PROPERTY_FONTRELIEF,aNoConverter)));
+ s_aNameMap.insert(TPropertyNamePair::value_type(PROPERTY_CHARFONTHEIGHT,TPropertyConverter(PROPERTY_FONTHEIGHT,aNoConverter)));
+ s_aNameMap.insert(TPropertyNamePair::value_type(PROPERTY_CHARSTRIKEOUT,TPropertyConverter(PROPERTY_FONTSTRIKEOUT,aNoConverter)));
+ s_aNameMap.insert(TPropertyNamePair::value_type(PROPERTY_CONTROLTEXTEMPHASISMARK,TPropertyConverter(PROPERTY_FONTEMPHASISMARK,aNoConverter)));
+ s_aNameMap.insert(TPropertyNamePair::value_type(PROPERTY_CONTROLBORDER,TPropertyConverter(PROPERTY_BORDER,aNoConverter)));
+ s_aNameMap.insert(TPropertyNamePair::value_type(PROPERTY_CONTROLBORDERCOLOR,TPropertyConverter(PROPERTY_BORDERCOLOR,aNoConverter)));
+
+ ::boost::shared_ptr<AnyConverter> aParaAdjust(new ParaAdjust());
+ s_aNameMap.insert(TPropertyNamePair::value_type(PROPERTY_PARAADJUST,TPropertyConverter(PROPERTY_ALIGN,aParaAdjust)));
+ }
+ return s_aNameMap;
+ }
case OBJ_DLG_FORMATTEDFIELD:
{
static TPropertyNamePair s_aNameMap;
if ( s_aNameMap.empty() )
{
- s_aNameMap.insert(TPropertyNamePair::value_type(PROPERTY_CHARCOLOR,PROPERTY_TEXTCOLOR));
- s_aNameMap.insert(TPropertyNamePair::value_type(PROPERTY_CONTROLBACKGROUND,PROPERTY_BACKGROUNDCOLOR));
- s_aNameMap.insert(TPropertyNamePair::value_type(PROPERTY_CHARUNDERLINECOLOR,PROPERTY_TEXTLINECOLOR));
- s_aNameMap.insert(TPropertyNamePair::value_type(PROPERTY_CHARRELIEF,PROPERTY_FONTRELIEF));
- s_aNameMap.insert(TPropertyNamePair::value_type(PROPERTY_CHARFONTHEIGHT,PROPERTY_FONTHEIGHT));
- s_aNameMap.insert(TPropertyNamePair::value_type(PROPERTY_CHARSTRIKEOUT,PROPERTY_FONTSTRIKEOUT));
- s_aNameMap.insert(TPropertyNamePair::value_type(PROPERTY_CONTROLTEXTEMPHASISMARK,PROPERTY_FONTEMPHASISMARK));
- s_aNameMap.insert(TPropertyNamePair::value_type(PROPERTY_CONTROLBORDER,PROPERTY_BORDER));
- s_aNameMap.insert(TPropertyNamePair::value_type(PROPERTY_CONTROLBORDERCOLOR,PROPERTY_BORDERCOLOR));
- s_aNameMap.insert(TPropertyNamePair::value_type(PROPERTY_PARAADJUST,PROPERTY_ALIGN));
+ ::boost::shared_ptr<AnyConverter> aNoConverter(new AnyConverter());
+ s_aNameMap.insert(TPropertyNamePair::value_type(PROPERTY_CHARCOLOR,TPropertyConverter(PROPERTY_TEXTCOLOR,aNoConverter)));
+ s_aNameMap.insert(TPropertyNamePair::value_type(PROPERTY_CONTROLBACKGROUND,TPropertyConverter(PROPERTY_BACKGROUNDCOLOR,aNoConverter)));
+ s_aNameMap.insert(TPropertyNamePair::value_type(PROPERTY_CHARUNDERLINECOLOR,TPropertyConverter(PROPERTY_TEXTLINECOLOR,aNoConverter)));
+ s_aNameMap.insert(TPropertyNamePair::value_type(PROPERTY_CHARRELIEF,TPropertyConverter(PROPERTY_FONTRELIEF,aNoConverter)));
+ s_aNameMap.insert(TPropertyNamePair::value_type(PROPERTY_CHARFONTHEIGHT,TPropertyConverter(PROPERTY_FONTHEIGHT,aNoConverter)));
+ s_aNameMap.insert(TPropertyNamePair::value_type(PROPERTY_CHARSTRIKEOUT,TPropertyConverter(PROPERTY_FONTSTRIKEOUT,aNoConverter)));
+ s_aNameMap.insert(TPropertyNamePair::value_type(PROPERTY_CONTROLTEXTEMPHASISMARK,TPropertyConverter(PROPERTY_FONTEMPHASISMARK,aNoConverter)));
+ s_aNameMap.insert(TPropertyNamePair::value_type(PROPERTY_CONTROLBORDER,TPropertyConverter(PROPERTY_BORDER,aNoConverter)));
+ s_aNameMap.insert(TPropertyNamePair::value_type(PROPERTY_CONTROLBORDERCOLOR,TPropertyConverter(PROPERTY_BORDERCOLOR,aNoConverter)));
+ //s_aNameMap.insert(TPropertyNamePair::value_type(PROPERTY_PARAADJUST,TPropertyConverter(PROPERTY_ALIGN,aNoConverter)));
+ ::boost::shared_ptr<AnyConverter> aParaAdjust(new ParaAdjust());
+ s_aNameMap.insert(TPropertyNamePair::value_type(PROPERTY_PARAADJUST,TPropertyConverter(PROPERTY_ALIGN,aParaAdjust)));
}
return s_aNameMap;
}
@@ -221,8 +306,9 @@ const TPropertyNamePair& getPropertyNameMap(sal_uInt16 _nObjectId)
static TPropertyNamePair s_aNameMap;
if ( s_aNameMap.empty() )
{
- s_aNameMap.insert(TPropertyNamePair::value_type(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("FillColor")),PROPERTY_CONTROLBACKGROUND));
- s_aNameMap.insert(TPropertyNamePair::value_type(PROPERTY_PARAADJUST,PROPERTY_ALIGN));
+ ::boost::shared_ptr<AnyConverter> aNoConverter(new AnyConverter());
+ s_aNameMap.insert(TPropertyNamePair::value_type(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("FillColor")),TPropertyConverter(PROPERTY_CONTROLBACKGROUND,aNoConverter)));
+ s_aNameMap.insert(TPropertyNamePair::value_type(PROPERTY_PARAADJUST,TPropertyConverter(PROPERTY_ALIGN,aNoConverter)));
}
return s_aNameMap;
}
@@ -424,8 +510,7 @@ OCustomShape::OCustomShape(const uno::Reference< report::XReportComponent>& _xCo
,OObjectBase(_xComponent)
{
DBG_CTOR( rpt_OCustomShape, NULL);
- // start listening
- mxUnoShape = uno::Reference< uno::XInterface >(_xComponent,uno::UNO_QUERY);
+ impl_setUnoShape( uno::Reference< uno::XInterface >(_xComponent,uno::UNO_QUERY) );
m_bIsListening = sal_True;
}
//----------------------------------------------------------------------------
@@ -441,7 +526,6 @@ OCustomShape::OCustomShape(const ::rtl::OUString& _sComponentName)
OCustomShape::~OCustomShape()
{
DBG_DTOR( rpt_OCustomShape, NULL);
- //mxUnoShape = uno::WeakReference< uno::XInterface >();
}
// -----------------------------------------------------------------------------
UINT16 OCustomShape::GetObjIdentifier() const
@@ -588,7 +672,10 @@ OUnoObject::OUnoObject(const uno::Reference< report::XReportComponent>& _xCompon
,m_nObjectType(_nObjectType)
{
DBG_CTOR( rpt_OUnoObject, NULL);
- mxUnoShape = uno::Reference< uno::XInterface >(_xComponent,uno::UNO_QUERY);
+ impl_setUnoShape( uno::Reference< uno::XInterface >( _xComponent, uno::UNO_QUERY ) );
+
+ if ( rModelName.getLength() )
+ impl_initializeModel_nothrow();
if ( rModelName.getLength() )
impl_initializeModel_nothrow();
@@ -597,7 +684,6 @@ OUnoObject::OUnoObject(const uno::Reference< report::XReportComponent>& _xCompon
OUnoObject::~OUnoObject()
{
DBG_DTOR( rpt_OUnoObject, NULL);
- //mxUnoShape = uno::WeakReference< uno::XInterface >();
}
// -----------------------------------------------------------------------------
void OUnoObject::impl_initializeModel_nothrow()
@@ -926,22 +1012,19 @@ OOle2Obj::OOle2Obj(const uno::Reference< report::XReportComponent>& _xComponent,
:SdrOle2Obj()
,OObjectBase(_xComponent)
,m_nType(_nType)
+ ,m_bOnlyOnce(true)
{
DBG_CTOR( rpt_OOle2Obj, NULL);
- // start listening
- mxUnoShape = uno::Reference< uno::XInterface >(_xComponent,uno::UNO_QUERY);
+ impl_setUnoShape( uno::Reference< uno::XInterface >( _xComponent, uno::UNO_QUERY ) );
m_bIsListening = sal_True;
- //uno::Reference< embed::XEmbeddedObject > xEmbed(_xComponent,uno::UNO_QUERY);
- //OSL_ENSURE(xEmbed.is(),"This is no embedded object!");
-
- //SetObjRef(xEmbed);
}
//----------------------------------------------------------------------------
OOle2Obj::OOle2Obj(const ::rtl::OUString& _sComponentName,UINT16 _nType)
:SdrOle2Obj()
,OObjectBase(_sComponentName)
,m_nType(_nType)
+ ,m_bOnlyOnce(true)
{
DBG_CTOR( rpt_OOle2Obj, NULL);
m_bIsListening = sal_True;
@@ -1123,17 +1206,42 @@ SdrObject* OOle2Obj::Clone() const
// -----------------------------------------------------------------------------
void OOle2Obj::impl_createDataProvider_nothrow(const uno::Reference< frame::XModel>& _xModel)
{
- uno::Reference < embed::XEmbeddedObject > xObj = GetObjRef();
- uno::Reference< chart2::data::XDataReceiver > xReceiver;
- uno::Reference< embed::XComponentSupplier > xCompSupp( xObj, uno::UNO_QUERY );
- if( xCompSupp.is())
- xReceiver.set( xCompSupp->getComponent(), uno::UNO_QUERY );
- OSL_ASSERT( xReceiver.is());
- if( xReceiver.is() )
+ try
+ {
+ uno::Reference < embed::XEmbeddedObject > xObj = GetObjRef();
+ uno::Reference< chart2::data::XDataReceiver > xReceiver;
+ uno::Reference< embed::XComponentSupplier > xCompSupp( xObj, uno::UNO_QUERY );
+ if( xCompSupp.is())
+ xReceiver.set( xCompSupp->getComponent(), uno::UNO_QUERY );
+ OSL_ASSERT( xReceiver.is());
+ if( xReceiver.is() )
+ {
+ uno::Reference< lang::XMultiServiceFactory> xFac(_xModel,uno::UNO_QUERY);
+ uno::Reference< chart2::data::XDatabaseDataProvider > xDataProvider( xFac->createInstance(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.chart2.data.DataProvider"))),uno::UNO_QUERY);
+ xReceiver->attachDataProvider( xDataProvider.get() );
+ } // if( xReceiver.is() )
+ }
+ catch(uno::Exception)
{
- uno::Reference< lang::XMultiServiceFactory> xFac(_xModel,uno::UNO_QUERY);
- uno::Reference< chart2::data::XDatabaseDataProvider > xDataProvider( xFac->createInstance(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.chart2.data.DataProvider"))),uno::UNO_QUERY);
- xReceiver->attachDataProvider( xDataProvider.get() );
+ }
+}
+// -----------------------------------------------------------------------------
+void OOle2Obj::initializeOle()
+{
+ if ( m_bOnlyOnce )
+ {
+ m_bOnlyOnce = false;
+ uno::Reference < embed::XEmbeddedObject > xObj = GetObjRef();
+ OReportModel* pRptModel = static_cast<OReportModel*>(GetModel());
+ pRptModel->GetUndoEnv().AddElement(lcl_getDataProvider(xObj));
+
+ uno::Reference< embed::XComponentSupplier > xCompSupp( xObj, uno::UNO_QUERY );
+ if( xCompSupp.is() )
+ {
+ uno::Reference< beans::XPropertySet > xChartProps( xCompSupp->getComponent(), uno::UNO_QUERY );
+ if ( xChartProps.is() )
+ xChartProps->setPropertyValue(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("NullDate")),uno::makeAny(util::DateTime(0,0,0,0,1,1,1900)));
+ }
}
}
// -----------------------------------------------------------------------------
@@ -1155,8 +1263,8 @@ void OOle2Obj::initializeChart( const uno::Reference< frame::XModel>& _xModel)
if ( !lcl_getDataProvider(xObj).is() )
impl_createDataProvider_nothrow(_xModel);
- uno::Reference< util::XNumberFormatsSupplier > xNumberFormatsSupplier( _xModel, uno::UNO_QUERY );
- xReceiver->attachNumberFormatsSupplier( xNumberFormatsSupplier );
+ OReportModel* pRptModel = static_cast<OReportModel*>(GetModel());
+ pRptModel->GetUndoEnv().AddElement(lcl_getDataProvider(xObj));
uno::Sequence< beans::PropertyValue > aArgs( 4 );
aArgs[0] = beans::PropertyValue(
diff --git a/reportdesign/source/core/sdr/RptPage.cxx b/reportdesign/source/core/sdr/RptPage.cxx
index 1db6b8e95c98..4d302a491a06 100644
--- a/reportdesign/source/core/sdr/RptPage.cxx
+++ b/reportdesign/source/core/sdr/RptPage.cxx
@@ -187,6 +187,7 @@ void OReportPage::removeTempObject(SdrObject *_pToRemoveObj)
{
SdrObject* pObject = RemoveObject(i);
(void)pObject;
+ break;
// delete pObject;
}
}
@@ -195,6 +196,7 @@ void OReportPage::removeTempObject(SdrObject *_pToRemoveObj)
void OReportPage::resetSpecialMode()
{
+ const sal_Bool bChanged = rModel.IsChanged();
::std::vector<SdrObject*>::iterator aIter = m_aTemporaryObjectList.begin();
::std::vector<SdrObject*>::iterator aEnd = m_aTemporaryObjectList.end();
@@ -202,6 +204,8 @@ void OReportPage::resetSpecialMode()
{
removeTempObject(*aIter);
}
+ m_aTemporaryObjectList.clear();
+ rModel.SetChanged(bChanged);
m_bSpecialInsertMode = false;
}
diff --git a/reportdesign/source/core/sdr/UndoActions.cxx b/reportdesign/source/core/sdr/UndoActions.cxx
index 4fd0fbad8dd7..7c2bb2bd98e5 100644
--- a/reportdesign/source/core/sdr/UndoActions.cxx
+++ b/reportdesign/source/core/sdr/UndoActions.cxx
@@ -446,9 +446,6 @@ Reference< XPropertySet> OUndoPropertyReportSectionAction::getObject()
{
return m_pMemberFunction(&m_aReportHelper).get();
}
-
-
-
//============================================================================
} // rptui
//============================================================================
diff --git a/reportdesign/source/filter/xml/xmlExport.cxx b/reportdesign/source/filter/xml/xmlExport.cxx
index add9ea18b7a8..63a76c047195 100644
--- a/reportdesign/source/filter/xml/xmlExport.cxx
+++ b/reportdesign/source/filter/xml/xmlExport.cxx
@@ -323,7 +323,7 @@ ORptExport::ORptExport(const Reference< XMultiServiceFactory >& _rxMSF,sal_uInt1
UniReference < XMLPropertySetMapper > xPropMapper(new XMLTextPropertySetMapper( TEXT_PROP_MAP_PARA ));
m_xParaPropMapper = new OSpecialHanldeXMLExportPropertyMapper( xPropMapper);
- //m_xParaPropMapper->ChainExportMapper(XMLTextParagraphExport::CreateParaExtPropMapper(*this));
+ // m_xParaPropMapper->ChainExportMapper(XMLTextParagraphExport::CreateParaExtPropMapper(*this));
::rtl::OUString sFamily( GetXMLToken(XML_PARAGRAPH) );
::rtl::OUString aPrefix( String( 'P' ) );
@@ -948,6 +948,10 @@ void ORptExport::exportContainer(const Reference< XSection>& _xSection)
AddAttribute(XML_NAMESPACE_FORM, XML_IMAGE_DATA,sTargetLocation);
}
bExportData = sal_True;
+ ::rtl::OUStringBuffer sValue;
+ const SvXMLEnumMapEntry* aXML_ImageScaleEnumMap = OXMLHelper::GetImageScaleOptions();
+ if ( SvXMLUnitConverter::convertEnum( sValue, xImage->getScaleMode(),aXML_ImageScaleEnumMap ) )
+ AddAttribute(XML_NAMESPACE_REPORT, XML_SCALE, sValue.makeStringAndClear() );
}
else if ( xReportDefinition.is() )
{
@@ -1268,37 +1272,37 @@ void ORptExport::exportAutoStyle(XPropertySet* _xProp,const Reference<XFormatted
}
else
{
- sal_Int32 nTextAlignIndex = m_xCellStylesExportPropertySetMapper->getPropertySetMapper()->FindEntryIndex( CTF_SD_SHAPE_PARA_ADJUST );
- if ( nTextAlignIndex != -1 )
- {
- ::std::vector< XMLPropertyState >::iterator aIter = aPropertyStates.begin();
- ::std::vector< XMLPropertyState >::iterator aEnd = aPropertyStates.end();
- for (; aIter != aEnd; ++aIter)
- {
- if ( aIter->mnIndex == nTextAlignIndex )
- {
- sal_Int16 nTextAlign = 0;
- aIter->maValue >>= nTextAlign;
- switch(nTextAlign)
- {
- case awt::TextAlign::LEFT:
- nTextAlign = style::ParagraphAdjust_LEFT;
- break;
- case awt::TextAlign::CENTER:
- nTextAlign = style::ParagraphAdjust_CENTER;
- break;
- case awt::TextAlign::RIGHT:
- nTextAlign = style::ParagraphAdjust_RIGHT;
- break;
- default:
- OSL_ENSURE(0,"Illegal text alignment value!");
- break;
- }
- aIter->maValue <<= nTextAlign;
- break;
- }
- }
- }
+ //sal_Int32 nTextAlignIndex = m_xCellStylesExportPropertySetMapper->getPropertySetMapper()->FindEntryIndex( CTF_SD_SHAPE_PARA_ADJUST );
+ //if ( nTextAlignIndex != -1 )
+ //{
+ // ::std::vector< XMLPropertyState >::iterator aIter = aPropertyStates.begin();
+ // ::std::vector< XMLPropertyState >::iterator aEnd = aPropertyStates.end();
+ // for (; aIter != aEnd; ++aIter)
+ // {
+ // if ( aIter->mnIndex == nTextAlignIndex )
+ // {
+ // sal_Int16 nTextAlign = 0;
+ // aIter->maValue >>= nTextAlign;
+ // switch(nTextAlign)
+ // {
+ // case awt::TextAlign::LEFT:
+ // nTextAlign = style::ParagraphAdjust_LEFT;
+ // break;
+ // case awt::TextAlign::CENTER:
+ // nTextAlign = style::ParagraphAdjust_CENTER;
+ // break;
+ // case awt::TextAlign::RIGHT:
+ // nTextAlign = style::ParagraphAdjust_RIGHT;
+ // break;
+ // default:
+ // OSL_ENSURE(0,"Illegal text alignment value!");
+ // break;
+ // }
+ // aIter->maValue <<= nTextAlign;
+ // break;
+ // }
+ // }
+ //}
const Reference<XFormattedField> xFormattedField(_xProp,uno::UNO_QUERY);
if ( (_xParentFormattedField.is() || xFormattedField.is()) && !aPropertyStates.empty() )
{
diff --git a/reportdesign/source/filter/xml/xmlExportDocumentHandler.cxx b/reportdesign/source/filter/xml/xmlExportDocumentHandler.cxx
index f4a394263234..73df0a049241 100644
--- a/reportdesign/source/filter/xml/xmlExportDocumentHandler.cxx
+++ b/reportdesign/source/filter/xml/xmlExportDocumentHandler.cxx
@@ -88,9 +88,11 @@ void lcl_correctCellAddress(const ::rtl::OUString & _sName, const uno::Reference
ExportDocumentHandler::ExportDocumentHandler(uno::Reference< uno::XComponentContext > const & context) :
m_xContext(context)
,m_nCurrentCellIndex(0)
+ ,m_nColumnCount(0)
,m_bTableRowsStarted(false)
,m_bFirstRowExported(false)
,m_bExportChar(false)
+ ,m_bCountColumnHeader(false)
{
}
// -----------------------------------------------------------------------------
@@ -189,6 +191,17 @@ void SAL_CALL ExportDocumentHandler::startElement(const ::rtl::OUString & _sName
pList->AddAttribute(lcl_createAttribute(XML_NP_OFFICE,XML_MIMETYPE),MIMETYPE_OASIS_OPENDOCUMENT_CHART);
m_xDelegatee->startElement(lcl_createAttribute(XML_NP_OFFICE,XML_REPORT),xNewAttribs);
+
+ const ::rtl::OUString sTableCalc = lcl_createAttribute(XML_NP_TABLE,XML_CALCULATION_SETTINGS);
+ m_xDelegatee->startElement(sTableCalc,NULL);
+ pList = new SvXMLAttributeList();
+ uno::Reference< xml::sax::XAttributeList > xNullAttr = pList;
+ pList->AddAttribute(lcl_createAttribute(XML_NP_TABLE,XML_DATE_VALUE),::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("1900-01-01")));
+
+ const ::rtl::OUString sNullDate = lcl_createAttribute(XML_NP_TABLE,XML_NULL_DATE);
+ m_xDelegatee->startElement(sNullDate,xNullAttr);
+ m_xDelegatee->endElement(sNullDate);
+ m_xDelegatee->endElement(sTableCalc);
bExport = false;
}
else if ( _sName.equalsAscii("table:table") )
@@ -196,6 +209,14 @@ void SAL_CALL ExportDocumentHandler::startElement(const ::rtl::OUString & _sName
m_xDelegatee->startElement(lcl_createAttribute(XML_NP_RPT,XML_DETAIL),NULL);
lcl_exportPrettyPrinting(m_xDelegatee);
}
+ else if ( _sName.equalsAscii("table:table-header-rows") )
+ {
+ m_bCountColumnHeader = true;
+ }
+ else if ( m_bCountColumnHeader && _sName.equalsAscii("table:table-cell") )
+ {
+ ++m_nColumnCount;
+ }
else if ( _sName.equalsAscii("table:table-rows") )
{
m_xDelegatee->startElement(_sName,xAttribs);
@@ -249,6 +270,10 @@ void SAL_CALL ExportDocumentHandler::endElement(const ::rtl::OUString & _sName)
lcl_exportPrettyPrinting(m_xDelegatee);
sNewName = lcl_createAttribute(XML_NP_RPT,XML_DETAIL);
}
+ else if ( _sName.equalsAscii("table:table-header-rows") )
+ {
+ m_bCountColumnHeader = false;
+ }
else if ( _sName.equalsAscii("table:table-rows") )
m_bTableRowsStarted = false;
else if ( m_bTableRowsStarted && m_bFirstRowExported && (_sName.equalsAscii("table:table-row") || _sName.equalsAscii("table:table-cell")) )
@@ -360,8 +385,26 @@ void ExportDocumentHandler::exportTableRows()
uno::Reference< xml::sax::XAttributeList > xCellAtt = pCellAtt;
pCellAtt->AddAttribute(sValueType,s_sString);
+ bool bRemoveString = true;
::rtl::OUString sFormula;
const sal_Int32 nCount = m_aColumns.getLength();
+ if ( m_nColumnCount > nCount )
+ {
+ const sal_Int32 nEmptyCellCount = m_nColumnCount - nCount;
+ for(sal_Int32 i = 0; i < nEmptyCellCount ; ++i)
+ {
+ m_xDelegatee->startElement(sCell,xCellAtt);
+ if ( bRemoveString )
+ {
+ bRemoveString = false;
+ pCellAtt->RemoveAttribute(sValueType);
+ pCellAtt->AddAttribute(sValueType,s_sFloat);
+ } // if ( i == 0 )
+ m_xDelegatee->startElement(sP,NULL);
+ m_xDelegatee->endElement(sP);
+ m_xDelegatee->endElement(sCell);
+ }
+ }
for(sal_Int32 i = 0; i < nCount ; ++i)
{
sFormula = s_sFieldPrefix;
@@ -372,8 +415,9 @@ void ExportDocumentHandler::exportTableRows()
pList->AddAttribute(sFormulaAttrib,sFormula);
m_xDelegatee->startElement(sCell,xCellAtt);
- if ( i == 0 )
+ if ( bRemoveString )
{
+ bRemoveString = false;
pCellAtt->RemoveAttribute(sValueType);
pCellAtt->AddAttribute(sValueType,s_sFloat);
}
diff --git a/reportdesign/source/filter/xml/xmlExportDocumentHandler.hxx b/reportdesign/source/filter/xml/xmlExportDocumentHandler.hxx
index 33cad946997a..3da9f99ca9d1 100644
--- a/reportdesign/source/filter/xml/xmlExportDocumentHandler.hxx
+++ b/reportdesign/source/filter/xml/xmlExportDocumentHandler.hxx
@@ -96,9 +96,11 @@ private:
::com::sun::star::uno::Reference< ::com::sun::star::chart2::data::XDatabaseDataProvider > m_xDatabaseDataProvider;
::com::sun::star::uno::Sequence< ::rtl::OUString > m_aColumns;
sal_Int32 m_nCurrentCellIndex;
+ sal_Int32 m_nColumnCount;
bool m_bTableRowsStarted;
bool m_bFirstRowExported;
bool m_bExportChar;
+ bool m_bCountColumnHeader;
};
// -----------------------------------------------------------------------------
} // namespace rptxml
diff --git a/reportdesign/source/filter/xml/xmlHelper.cxx b/reportdesign/source/filter/xml/xmlHelper.cxx
index 1b81d87a1119..d0e75499ace0 100644
--- a/reportdesign/source/filter/xml/xmlHelper.cxx
+++ b/reportdesign/source/filter/xml/xmlHelper.cxx
@@ -43,6 +43,7 @@
#include <com/sun/star/awt/FontDescriptor.hpp>
#include <com/sun/star/awt/TextAlign.hpp>
#include <com/sun/star/awt/ImagePosition.hpp>
+#include <com/sun/star/awt/ImageScaleMode.hpp>
#include <xmloff/prstylei.hxx>
#include "xmlstrings.hrc"
#include "xmlEnums.hxx"
@@ -59,7 +60,7 @@
#include <com/sun/star/report/XReportControlFormat.hpp>
#include <com/sun/star/form/ListSourceType.hpp>
#include <com/sun/star/sdb/CommandType.hpp>
-#include <com/sun/star/drawing/TextVerticalAdjust.hpp>
+#include <com/sun/star/style/VerticalAlignment.hpp>
#include <xmloff/EnumPropertyHdl.hxx>
#define XML_RPT_ALGINMENT (XML_DB_TYPES_START+1)
@@ -85,21 +86,22 @@ OPropertyHandlerFactory::~OPropertyHandlerFactory()
const XMLPropertyHandler* OPropertyHandlerFactory::GetPropertyHandler(sal_Int32 _nType) const
{
const XMLPropertyHandler* pHandler = NULL;
+ sal_Int32 nType = _nType;
+ nType &= MID_FLAG_MASK;
- switch(_nType)
+ switch(nType)
{
case XML_RPT_ALGINMENT:
{
static SvXMLEnumMapEntry __READONLY_DATA pXML_VerticalAlign_Enum[] =
{
- { XML_TOP, drawing::TextVerticalAdjust_TOP },
- { XML_MIDDLE, drawing::TextVerticalAdjust_CENTER },
- { XML_BOTTOM, drawing::TextVerticalAdjust_BOTTOM },
- { XML_JUSTIFY, drawing::TextVerticalAdjust_BLOCK },
+ { XML_TOP, style::VerticalAlignment_TOP },
+ { XML_MIDDLE, style::VerticalAlignment_MIDDLE },
+ { XML_BOTTOM, style::VerticalAlignment_BOTTOM },
{ XML_TOKEN_INVALID, 0 }
};
- pHandler = new XMLEnumPropertyHdl( pXML_VerticalAlign_Enum, ::getCppuType((const com::sun::star::drawing::TextVerticalAdjust*)0) );
+ pHandler = new XMLEnumPropertyHdl( pXML_VerticalAlign_Enum, ::getCppuType((const com::sun::star::style::VerticalAlignment*)0) );
}
break;
case (XML_SD_TYPES_START+34):
@@ -110,6 +112,8 @@ const XMLPropertyHandler* OPropertyHandlerFactory::GetPropertyHandler(sal_Int32
if ( !pHandler )
pHandler = OControlPropertyHandlerFactory::GetPropertyHandler(_nType);
+ else
+ PutHdlCache(nType, pHandler);
return pHandler;
}
// -----------------------------------------------------------------------------
@@ -134,13 +138,13 @@ UniReference < XMLPropertySetMapper > OXMLHelper::GetCellStylePropertyMap(bool _
MAP_CONST_C( PROPERTY_CONTROLBACKGROUND,
FO, BACKGROUND_COLOR, XML_TYPE_COLORTRANSPARENT|MID_FLAG_MULTI_PROPERTY, 0 ),
+ MAP_CONST_C( PROPERTY_VERTICALALIGN, STYLE, VERTICAL_ALIGN, XML_RPT_ALGINMENT, 0 ),
MAP_CONST_C( PROPERTY_CONTROLBACKGROUNDTRANSPARENT,
FO, BACKGROUND_COLOR, XML_TYPE_ISTRANSPARENT|MID_FLAG_MERGE_ATTRIBUTE, 0 ),
MAP_CONST_P( PROPERTY_CONTROLBACKGROUND,
FO, BACKGROUND_COLOR, XML_TYPE_COLORTRANSPARENT|MID_FLAG_MULTI_PROPERTY, 0 ),
MAP_CONST_P( PROPERTY_CONTROLBACKGROUNDTRANSPARENT,
FO, BACKGROUND_COLOR, XML_TYPE_ISTRANSPARENT|MID_FLAG_MERGE_ATTRIBUTE, 0 ),
- GMAP( PROPERTY_SCALEMODE,STYLE,REPEAT, (XML_SD_TYPES_START+34)|MID_FLAG_MULTI_PROPERTY, 0 ),
MAP_CONST_C_ASCII( "BorderLeft", FO, BORDER_LEFT, XML_TYPE_BORDER, 0 ),
MAP_CONST_C_ASCII( "BorderRight", FO, BORDER_RIGHT, XML_TYPE_BORDER, 0 ),
MAP_CONST_C_ASCII( "BorderTop", FO, BORDER_TOP, XML_TYPE_BORDER, 0 ),
@@ -159,7 +163,8 @@ UniReference < XMLPropertySetMapper > OXMLHelper::GetCellStylePropertyMap(bool _
FO, BACKGROUND_COLOR, XML_TYPE_COLORTRANSPARENT|MID_FLAG_MULTI_PROPERTY, 0 ),
MAP_CONST_C( PROPERTY_CONTROLBACKGROUNDTRANSPARENT,
FO, BACKGROUND_COLOR, XML_TYPE_ISTRANSPARENT|MID_FLAG_MERGE_ATTRIBUTE, 0 ),
- GMAP( PROPERTY_SCALEMODE,STYLE,REPEAT, (XML_SD_TYPES_START+34)|MID_FLAG_MULTI_PROPERTY, 0 ),
+ MAP_CONST_C( PROPERTY_VERTICALALIGN,
+ STYLE, VERTICAL_ALIGN, XML_RPT_ALGINMENT, 0 ),
MAP_CONST_C_ASCII( "BorderLeft", FO, BORDER_LEFT, XML_TYPE_BORDER, 0 ),
MAP_CONST_C_ASCII( "BorderRight", FO, BORDER_RIGHT, XML_TYPE_BORDER, 0 ),
MAP_CONST_C_ASCII( "BorderTop", FO, BORDER_TOP, XML_TYPE_BORDER, 0 ),
@@ -231,26 +236,6 @@ const SvXMLEnumMapEntry* OXMLHelper::GetForceNewPageOptions()
return s_aXML_EnumMap;
}
// -----------------------------------------------------------------------------
-//// -----------------------------------------------------------------------------
-//const SvXMLEnumMapEntry* OXMLHelper::GetGroupOnOptions()
-//{
-// static SvXMLEnumMapEntry s_aXML_EnumMap[] =
-// {
-// // { XML_DEFAULT ,report::GroupOn::DEFAULT }, // default
-// { XML_PREFIX_CHARACTERS ,report::GroupOn::PREFIX_CHARACTERS },
-// { XML_YEAR ,report::GroupOn::YEAR },
-// { XML_QUARTAL , report::GroupOn::QUARTAL },
-// { XML_MONTH , report::GroupOn::MONTH },
-// { XML_WEEK , report::GroupOn::WEEK },
-// { XML_DAY , report::GroupOn::DAY },
-// { XML_HOUR , report::GroupOn::HOUR },
-// { XML_MINUTE , report::GroupOn::MINUTE },
-// { XML_INTERVAL , report::GroupOn::INTERVAL },
-// { XML_TOKEN_INVALID, 0 }
-// };
-// return s_aXML_EnumMap;
-//}
-// -----------------------------------------------------------------------------
const SvXMLEnumMapEntry* OXMLHelper::GetKeepTogetherOptions()
{
static SvXMLEnumMapEntry s_aXML_EnumMap[] =
@@ -352,33 +337,10 @@ void OXMLHelper::copyStyleElements(const bool _bOld,const ::rtl::OUString& _sSty
xProp->getPropertyValue(PROPERTY_FONTTYPE) >>= aFont.Type;
uno::Reference<report::XReportControlFormat> xReportControlModel(_xProp,uno::UNO_QUERY);
if ( xReportControlModel.is() && aFont.Name.getLength() )
- try
- {
- xReportControlModel->setFontDescriptor(aFont);
- }
- catch(beans::UnknownPropertyException){}
-
- if ( xReportControlModel.is() )
{
try
{
- sal_Int16 nTextAlign = xReportControlModel->getParaAdjust();
- switch(nTextAlign)
- {
- case style::ParagraphAdjust_LEFT:
- nTextAlign = awt::TextAlign::LEFT;
- break;
- case style::ParagraphAdjust_CENTER:
- nTextAlign = awt::TextAlign::CENTER;
- break;
- case style::ParagraphAdjust_RIGHT:
- nTextAlign = awt::TextAlign::RIGHT;
- break;
- default:
- OSL_ENSURE(0,"Illegal text alignment value!");
- break;
- }
- xReportControlModel->setParaAdjust(nTextAlign);
+ xReportControlModel->setFontDescriptor(aFont);
}
catch(beans::UnknownPropertyException){}
}
@@ -442,5 +404,18 @@ SvXMLTokenMap* OXMLHelper::GetSubDocumentElemTokenMap()
return new SvXMLTokenMap( aElemTokenMap );
}
// -----------------------------------------------------------------------------
+const SvXMLEnumMapEntry* OXMLHelper::GetImageScaleOptions()
+{
+ static SvXMLEnumMapEntry s_aXML_EnumMap[] =
+ {
+ // { XML_NONE, awt::ImageScaleMode::None }, // default
+ { XML_ISOTROPIC, awt::ImageScaleMode::Isotropic },
+ { XML_ANISOTROPIC, awt::ImageScaleMode::Anisotropic },
+ { XML_TOKEN_INVALID, 0 }
+ };
+ return s_aXML_EnumMap;
+}
+// -----------------------------------------------------------------------------
+// -----------------------------------------------------------------------------
} // rptxml
// -----------------------------------------------------------------------------
diff --git a/reportdesign/source/filter/xml/xmlHelper.hxx b/reportdesign/source/filter/xml/xmlHelper.hxx
index cfb0df81a213..909ae9defeda 100644
--- a/reportdesign/source/filter/xml/xmlHelper.hxx
+++ b/reportdesign/source/filter/xml/xmlHelper.hxx
@@ -39,8 +39,7 @@
#include <memory>
-#define CTF_RPT_NUMBERFORMAT (XML_DB_CTF_START + 1)
-#define CTF_RPT_PARAVERTALIGNMENT (XML_DB_CTF_START + 2)
+#define CTF_RPT_NUMBERFORMAT (XML_DB_CTF_START + 1)
#define XML_STYLE_FAMILY_REPORT_ID 700
#define XML_STYLE_FAMILY_REPORT_NAME "report-element"
@@ -76,6 +75,7 @@ namespace rptxml
static const SvXMLEnumMapEntry* GetForceNewPageOptions();
static const SvXMLEnumMapEntry* GetKeepTogetherOptions();
static const SvXMLEnumMapEntry* GetCommandTypeOptions();
+ static const SvXMLEnumMapEntry* GetImageScaleOptions();
static const XMLPropertyMapEntry* GetTableStyleProps();
static const XMLPropertyMapEntry* GetColumnStyleProps();
diff --git a/reportdesign/source/filter/xml/xmlImage.cxx b/reportdesign/source/filter/xml/xmlImage.cxx
index 33c0b58646b2..b1341a35c365 100644
--- a/reportdesign/source/filter/xml/xmlImage.cxx
+++ b/reportdesign/source/filter/xml/xmlImage.cxx
@@ -33,10 +33,12 @@
#include <xmloff/xmltoken.hxx>
#include <xmloff/xmlnmspe.hxx>
#include <xmloff/nmspmap.hxx>
+#include <xmloff/xmluconv.hxx>
#include "xmlEnums.hxx"
#include "xmlComponent.hxx"
#include "xmlReportElement.hxx"
#include "xmlControlProperty.hxx"
+#include "xmlHelper.hxx"
#include <tools/debug.hxx>
#include <svtools/pathoptions.hxx>
@@ -90,7 +92,19 @@ OXMLImage::OXMLImage( ORptFilter& rImport,
_xComponent->setPreserveIRI(s_sTRUE == sValue);
break;
case XML_TOK_SCALE:
- _xComponent->setScaleMode(s_sTRUE == sValue ? awt::ImageScaleMode::Anisotropic : awt::ImageScaleMode::None );
+ {
+ sal_uInt16 nRet = awt::ImageScaleMode::None;
+ if ( s_sTRUE == sValue )
+ {
+ nRet = awt::ImageScaleMode::Anisotropic;
+ }
+ else
+ {
+ const SvXMLEnumMapEntry* aXML_EnumMap = OXMLHelper::GetImageScaleOptions();
+ SvXMLUnitConverter::convertEnum( nRet, sValue, aXML_EnumMap );
+ }
+ _xComponent->setScaleMode( nRet );
+ }
break;
case XML_TOK_DATA_FORMULA:
_xComponent->setDataField(ORptFilter::convertFormula(sValue));
diff --git a/reportdesign/source/filter/xml/xmlImportDocumentHandler.cxx b/reportdesign/source/filter/xml/xmlImportDocumentHandler.cxx
index 32944bc81998..ea1095258261 100644
--- a/reportdesign/source/filter/xml/xmlImportDocumentHandler.cxx
+++ b/reportdesign/source/filter/xml/xmlImportDocumentHandler.cxx
@@ -58,7 +58,8 @@ using namespace ::xmloff::token;
::rtl::OUString lcl_createAttribute(const xmloff::token::XMLTokenEnum& _eNamespace,const xmloff::token::XMLTokenEnum& _eAttribute);
ImportDocumentHandler::ImportDocumentHandler(uno::Reference< uno::XComponentContext > const & context) :
- m_xContext(context)
+ m_xContext(context)
+ ,m_bOnlyOnce(true)
{
}
// -----------------------------------------------------------------------------
@@ -167,7 +168,6 @@ void SAL_CALL ImportDocumentHandler::startElement(const ::rtl::OUString & _sName
break;
}
}
- m_xDatabaseDataProvider->execute();
}
catch(uno::Exception&)
{
@@ -224,10 +224,52 @@ void SAL_CALL ImportDocumentHandler::startElement(const ::rtl::OUString & _sName
bExport = false;
else if ( _sName.equalsAscii("chart:plot-area"))
{
+ sal_Bool bHasCategories = sal_True;
+ const sal_Int16 nLength = (_xAttrList.is()) ? _xAttrList->getLength() : 0;
+ ::std::auto_ptr<SvXMLTokenMap> pMasterElemTokenMap( OXMLHelper::GetSubDocumentElemTokenMap());
+ for(sal_Int16 i = 0; i < nLength; ++i)
+ {
+ ::rtl::OUString sLocalName;
+ const rtl::OUString sAttrName = _xAttrList->getNameByIndex( i );
+ const sal_Int32 nColonPos = sAttrName.indexOf( sal_Unicode(':') );
+ if( -1L == nColonPos )
+ sLocalName = sAttrName;
+ else
+ sLocalName = sAttrName.copy( nColonPos + 1L );
+ if ( sLocalName.equalsAscii("data-source-has-labels") )
+ {
+ const rtl::OUString sValue = _xAttrList->getValueByIndex( i );
+ bHasCategories = sValue.equalsAscii("both");
+ break;
+ }
+ } // for(sal_Int16 i = 0; i < nLength; ++i)
+ beans::PropertyValue* pArgIter = m_aArguments.getArray();
+ beans::PropertyValue* pArgEnd = pArgIter + m_aArguments.getLength();
+ for(;pArgIter != pArgEnd;++pArgIter)
+ {
+ if ( pArgIter->Name.equalsAscii("HasCategories") )
+ {
+ pArgIter->Value <<= bHasCategories;
+ break;
+ }
+ } // for(;pArgIter != pArgEnd;++pArgIter)
+
+ if ( m_bOnlyOnce )
+ {
+ try
+ {
+ m_xDatabaseDataProvider->createDataSource(m_aArguments);
+ m_bOnlyOnce = false;
+ }
+ catch(uno::Exception)
+ {}
+ } // if ( m_bOnlyOnce )
+
SvXMLAttributeList* pList = new SvXMLAttributeList();
xNewAttribs = pList;
pList->AppendAttributeList(_xAttrList);
pList->AddAttribute(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("table:cell-range-address")),::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("local-table.$A$1:.$Z$65536")));
+
}
if ( bExport )
@@ -239,7 +281,9 @@ void SAL_CALL ImportDocumentHandler::endElement(const ::rtl::OUString & _sName)
bool bExport = true;
::rtl::OUString sNewName = _sName;
if ( _sName.equalsAscii("office:report") )
+ {
sNewName = lcl_createAttribute(XML_NP_OFFICE,XML_CHART);
+ }
else if ( _sName.equalsAscii("rpt:master-detail-fields") )
{
if ( !m_aMasterFields.empty() )
@@ -302,7 +346,9 @@ void SAL_CALL ImportDocumentHandler::initialize( const uno::Sequence< uno::Any >
uno::Reference< chart2::data::XDataReceiver > xReceiver(m_xModel,uno::UNO_QUERY_THROW);
xReceiver->attachDataProvider(m_xDatabaseDataProvider.get());
- }
+ } // if ( !m_xDatabaseDataProvider.is() )
+
+ m_aArguments = m_xDatabaseDataProvider->detectArguments(NULL);
uno::Reference< reflection::XProxyFactory > xProxyFactory( m_xContext->getServiceManager()->createInstanceWithContext(
::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.reflection.ProxyFactory")),m_xContext),
diff --git a/reportdesign/source/filter/xml/xmlImportDocumentHandler.hxx b/reportdesign/source/filter/xml/xmlImportDocumentHandler.hxx
index 8a8b126828fa..068fac8cb5f9 100644
--- a/reportdesign/source/filter/xml/xmlImportDocumentHandler.hxx
+++ b/reportdesign/source/filter/xml/xmlImportDocumentHandler.hxx
@@ -90,6 +90,7 @@ private:
::osl::Mutex m_aMutex;
::std::vector< ::rtl::OUString> m_aMasterFields;
::std::vector< ::rtl::OUString> m_aDetailFields;
+ ::com::sun::star::uno::Sequence< ::com::sun::star::beans::PropertyValue > m_aArguments;
::com::sun::star::uno::Reference< ::com::sun::star::uno::XComponentContext > m_xContext;
::com::sun::star::uno::Reference< ::com::sun::star::xml::sax::XDocumentHandler > m_xDelegatee;
::com::sun::star::uno::Reference< ::com::sun::star::uno::XAggregation > m_xProxy;
@@ -99,6 +100,7 @@ private:
::com::sun::star::uno::Reference< ::com::sun::star::chart2::data::XDatabaseDataProvider > m_xDatabaseDataProvider;
::std::auto_ptr<SvXMLTokenMap> m_pReportElemTokenMap;
+ bool m_bOnlyOnce;
};
// -----------------------------------------------------------------------------
} // namespace rptxml
diff --git a/reportdesign/source/filter/xml/xmlPropertyHandler.cxx b/reportdesign/source/filter/xml/xmlPropertyHandler.cxx
index a11965caf4be..33f04d81af30 100644
--- a/reportdesign/source/filter/xml/xmlPropertyHandler.cxx
+++ b/reportdesign/source/filter/xml/xmlPropertyHandler.cxx
@@ -48,12 +48,10 @@ DBG_NAME( rpt_OXMLRptPropHdlFactory )
OXMLRptPropHdlFactory::OXMLRptPropHdlFactory()
{
DBG_CTOR( rpt_OXMLRptPropHdlFactory,NULL);
-
}
// -----------------------------------------------------------------------------
OXMLRptPropHdlFactory::~OXMLRptPropHdlFactory()
{
-
DBG_DTOR( rpt_OXMLRptPropHdlFactory,NULL);
}
// -----------------------------------------------------------------------------
diff --git a/reportdesign/source/filter/xml/xmlfilter.cxx b/reportdesign/source/filter/xml/xmlfilter.cxx
index 80c2c2d885f6..51307c956c65 100644
--- a/reportdesign/source/filter/xml/xmlfilter.cxx
+++ b/reportdesign/source/filter/xml/xmlfilter.cxx
@@ -566,8 +566,8 @@ sal_Bool ORptFilter::implImport( const Sequence< PropertyValue >& rDescriptor )
{ MAP_LEN( "OldFormat" ), 1, &::getCppuType((const sal_Bool*)0), beans::PropertyAttribute::BOUND, 0 },
{ MAP_LEN( "StreamName"), 0, &::getCppuType( (::rtl::OUString *)0 ), beans::PropertyAttribute::MAYBEVOID, 0 },
{ MAP_LEN("PrivateData"), 0, &::getCppuType( (uno::Reference<XInterface> *)0 ), beans::PropertyAttribute::MAYBEVOID, 0 },
- { MAP_LEN( "BaseURI"), 0,&::getCppuType( (::rtl::OUString *)0 ),beans::PropertyAttribute::MAYBEVOID, 0 },
- { MAP_LEN( "StreamRelPath"), 0,&::getCppuType( (::rtl::OUString *)0 ),beans::PropertyAttribute::MAYBEVOID, 0 },
+ { MAP_LEN( "BaseURI"), 0, &::getCppuType( (::rtl::OUString *)0 ), beans::PropertyAttribute::MAYBEVOID, 0 },
+ { MAP_LEN( "StreamRelPath"), 0, &::getCppuType( (::rtl::OUString *)0 ), beans::PropertyAttribute::MAYBEVOID, 0 },
{ NULL, 0, 0, NULL, 0, 0 }
};
::comphelper::MediaDescriptor aDescriptor(rDescriptor);
diff --git a/reportdesign/source/inc/stringconstants.hrc b/reportdesign/source/inc/stringconstants.hrc
index c9f4c520c863..69482ef4b869 100644
--- a/reportdesign/source/inc/stringconstants.hrc
+++ b/reportdesign/source/inc/stringconstants.hrc
@@ -160,6 +160,7 @@ DECLARE_CONSTASCII_USTRING(PROPERTY_FONTFAMILY);
DECLARE_CONSTASCII_USTRING(PROPERTY_FONTHEIGHT);
DECLARE_CONSTASCII_USTRING(PROPERTY_CHARFONTHEIGHT);
DECLARE_CONSTASCII_USTRING(PROPERTY_FONTKERNING);
+DECLARE_CONSTASCII_USTRING(PROPERTY_FONT);
DECLARE_CONSTASCII_USTRING(PROPERTY_FONTNAME);
DECLARE_CONSTASCII_USTRING(PROPERTY_FONTORIENTATION);
DECLARE_CONSTASCII_USTRING(PROPERTY_FONTPITCH);
@@ -281,6 +282,7 @@ DECLARE_CONSTASCII_USTRING(PROPERTY_CHARKERNING );
DECLARE_CONSTASCII_USTRING(PROPERTY_ORDER );
DECLARE_CONSTASCII_USTRING(PROPERTY_APPLYFILTER );
+DECLARE_CONSTASCII_USTRING(PROPERTY_MAXROWS );
//============================================================
//= service names
diff --git a/reportdesign/source/inc/uistrings.hrc b/reportdesign/source/inc/uistrings.hrc
index 07d5f492ba89..356088a19b5f 100644
--- a/reportdesign/source/inc/uistrings.hrc
+++ b/reportdesign/source/inc/uistrings.hrc
@@ -73,7 +73,6 @@ DECLARE_CONSTASCII_USTRING(PROPERTY_FILLGRADIENTNAME );
DECLARE_CONSTASCII_USTRING(PROPERTY_FILLHATCHNAME );
DECLARE_CONSTASCII_USTRING(PROPERTY_FILLBITMAPNAME );
DECLARE_CONSTASCII_USTRING(PROPERTY_FILLSTYLE );
-
DECLARE_CONSTASCII_USTRING(DBTEXTBOXBOUNDCONTENT );
}
diff --git a/reportdesign/source/shared/stringconstants.cxx b/reportdesign/source/shared/stringconstants.cxx
index f0486bf9c92c..e4123f21e3e8 100644
--- a/reportdesign/source/shared/stringconstants.cxx
+++ b/reportdesign/source/shared/stringconstants.cxx
@@ -113,7 +113,7 @@ IMPLEMENT_CONSTASCII_USTRING(PROPERTY_FONTDESCRIPTORCOMPLEX , "FontDescriptorCom
IMPLEMENT_CONSTASCII_USTRING(PROPERTY_CONTROLTEXTEMPHASISMARK , "ControlTextEmphasis");
IMPLEMENT_CONSTASCII_USTRING(PROPERTY_CHARRELIEF , "CharRelief");
IMPLEMENT_CONSTASCII_USTRING(PROPERTY_CHARCOLOR , "CharColor");
-IMPLEMENT_CONSTASCII_USTRING(PROPERTY_VERTICALALIGN , "ParaVertAlignment");
+IMPLEMENT_CONSTASCII_USTRING(PROPERTY_VERTICALALIGN , "VerticalAlign");
IMPLEMENT_CONSTASCII_USTRING(PROPERTY_IMAGEPOSITION , "ImagePosition");
IMPLEMENT_CONSTASCII_USTRING(PROPERTY_IMAGEURL , "ImageURL");
IMPLEMENT_CONSTASCII_USTRING(PROPERTY_CHARUNDERLINECOLOR , "CharUnderlineColor");
@@ -154,6 +154,7 @@ IMPLEMENT_CONSTASCII_USTRING(PROPERTY_FONTFAMILY, "CharFontFamily");
IMPLEMENT_CONSTASCII_USTRING(PROPERTY_CHARFONTHEIGHT, "CharHeight");
IMPLEMENT_CONSTASCII_USTRING(PROPERTY_FONTHEIGHT, "FontHeight");
IMPLEMENT_CONSTASCII_USTRING(PROPERTY_FONTKERNING, "FontKerning");
+IMPLEMENT_CONSTASCII_USTRING(PROPERTY_FONT, "FontDescriptor");
IMPLEMENT_CONSTASCII_USTRING(PROPERTY_FONTNAME, "FontName");
IMPLEMENT_CONSTASCII_USTRING(PROPERTY_FONTORIENTATION, "CharRotation");
IMPLEMENT_CONSTASCII_USTRING(PROPERTY_FONTPITCH, "CharFontPitch");
@@ -273,5 +274,6 @@ IMPLEMENT_CONSTASCII_USTRING(PROPERTY_HYPERLINKNAME , "HyperLinkName");
IMPLEMENT_CONSTASCII_USTRING(PROPERTY_VISITEDCHARSTYLENAME, "VisitedCharStyleName");
IMPLEMENT_CONSTASCII_USTRING(PROPERTY_UNVISITEDCHARSTYLENAME, "UnvisitedCharStyleName");
-IMPLEMENT_CONSTASCII_USTRING(PROPERTY_ORDER, "Order");
-IMPLEMENT_CONSTASCII_USTRING(PROPERTY_APPLYFILTER, "ApplyFilter");
+IMPLEMENT_CONSTASCII_USTRING(PROPERTY_ORDER, "Order");
+IMPLEMENT_CONSTASCII_USTRING(PROPERTY_APPLYFILTER, "ApplyFilter");
+IMPLEMENT_CONSTASCII_USTRING(PROPERTY_MAXROWS, "MaxRows");
diff --git a/reportdesign/source/shared/uistrings.cxx b/reportdesign/source/shared/uistrings.cxx
index ceee0aea34f0..21d80cb19ad4 100644
--- a/reportdesign/source/shared/uistrings.cxx
+++ b/reportdesign/source/shared/uistrings.cxx
@@ -70,4 +70,3 @@ namespace rptui
IMPLEMENT_CONSTASCII_USTRING(DBTEXTBOXBOUNDCONTENT , "TextBoxBoundContent");
}
-
diff --git a/reportdesign/source/ui/dlg/AddField.cxx b/reportdesign/source/ui/dlg/AddField.cxx
index afc53270754a..034ff5f9c7b5 100644
--- a/reportdesign/source/ui/dlg/AddField.cxx
+++ b/reportdesign/source/ui/dlg/AddField.cxx
@@ -401,7 +401,6 @@ void OAddFieldWindow::Resize()
// Help text
Point aFTPos( aRelated.Width(), aFLPos.Y() + aFLSize.Height() + aRelated.Height() );
m_aHelpText.SetPosSizePixel( aFTPos, aHelpTextSize );
-
}
// -----------------------------------------------------------------------------
uno::Reference< sdbc::XConnection> OAddFieldWindow::getConnection() const
diff --git a/reportdesign/source/ui/inc/ReportController.hxx b/reportdesign/source/ui/inc/ReportController.hxx
index 43e17fcff67e..d84da255e9e3 100644
--- a/reportdesign/source/ui/inc/ReportController.hxx
+++ b/reportdesign/source/ui/inc/ReportController.hxx
@@ -49,7 +49,8 @@
#include <com/sun/star/report/XReportEngine.hpp>
#include <com/sun/star/report/XSection.hpp>
#include <com/sun/star/view/XSelectionSupplier.hpp>
-#include <cppuhelper/implbase4.hxx>
+#include <com/sun/star/embed/XVisualObject.hpp>
+#include <cppuhelper/implbase5.hxx>
#include <svtools/transfer.hxx>
#include <svtools/lstner.hxx>
#include <svx/svdedtv.hxx>
@@ -81,10 +82,11 @@ namespace rptui
class OSectionWindow;
typedef ::dbaui::OSingleDocumentController OReportController_BASE;
- typedef ::cppu::ImplHelper4 < ::com::sun::star::container::XContainerListener
+ typedef ::cppu::ImplHelper5 < ::com::sun::star::container::XContainerListener
, ::com::sun::star::beans::XPropertyChangeListener
, ::com::sun::star::view::XSelectionSupplier
, ::com::sun::star::util::XModeSelector
+ , ::com::sun::star::embed::XVisualObject
> OReportController_Listener;
class OReportController : public OReportController_BASE
@@ -114,6 +116,7 @@ namespace rptui
::com::sun::star::uno::Reference< ::com::sun::star::sdbc::XRowSet > m_xRowSet;
::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertyChangeListener > m_xRowSetMediator;
::com::sun::star::uno::Reference< ::com::sun::star::util::XNumberFormatter > m_xFormatter; // a number formatter working with the report's NumberFormatsSupplier
+ ::com::sun::star::awt::Size m_aVisualAreaSize;
::boost::shared_ptr<rptui::OReportModel>
m_aReportModel;
@@ -123,6 +126,7 @@ namespace rptui
sal_Int32 m_nSplitPos; /// the position of the splitter
sal_Int32 m_nPageNum; /// the page number from the restoreView call
sal_Int32 m_nSelectionCount;
+ ::sal_Int64 m_nAspect;
sal_Int16 m_nZoomValue;
SvxZoomType m_eZoomType;
sal_Bool m_bShowRuler;
@@ -133,6 +137,7 @@ namespace rptui
sal_Bool m_bHelplinesMove;
bool m_bChartEnabled;
bool m_bChartEnabledAsked;
+ bool m_bInGeneratePreview;
/** creates a formatted field in the given section with the given formula as data field
*
@@ -409,6 +414,12 @@ namespace rptui
virtual ::com::sun::star::uno::Sequence< ::rtl::OUString > SAL_CALL getSupportedModes( ) throw (::com::sun::star::uno::RuntimeException) ;
virtual ::sal_Bool SAL_CALL supportsMode( const ::rtl::OUString& aMode ) throw (::com::sun::star::uno::RuntimeException) ;
+ // XVisualObject
+ virtual void SAL_CALL setVisualAreaSize( ::sal_Int64 nAspect, const ::com::sun::star::awt::Size& aSize ) throw (::com::sun::star::lang::IllegalArgumentException, ::com::sun::star::embed::WrongStateException, ::com::sun::star::uno::Exception, ::com::sun::star::uno::RuntimeException);
+ virtual ::com::sun::star::awt::Size SAL_CALL getVisualAreaSize( ::sal_Int64 nAspect ) throw (::com::sun::star::lang::IllegalArgumentException, ::com::sun::star::embed::WrongStateException, ::com::sun::star::uno::Exception, ::com::sun::star::uno::RuntimeException);
+ virtual ::com::sun::star::embed::VisualRepresentation SAL_CALL getPreferredVisualRepresentation( ::sal_Int64 nAspect ) throw (::com::sun::star::lang::IllegalArgumentException, ::com::sun::star::embed::WrongStateException, ::com::sun::star::uno::Exception, ::com::sun::star::uno::RuntimeException);
+ virtual ::sal_Int32 SAL_CALL getMapUnit( ::sal_Int64 nAspect ) throw (::com::sun::star::uno::Exception, ::com::sun::star::uno::RuntimeException);
+
/** returns the current position of the splitter
*
diff --git a/reportdesign/source/ui/inc/ReportControllerObserver.hxx b/reportdesign/source/ui/inc/ReportControllerObserver.hxx
index 7d11bf0d0fa8..87468d61e303 100644
--- a/reportdesign/source/ui/inc/ReportControllerObserver.hxx
+++ b/reportdesign/source/ui/inc/ReportControllerObserver.hxx
@@ -73,8 +73,7 @@ namespace rptui
void switchListening(const ::com::sun::star::uno::Reference< ::com::sun::star::uno::XInterface >& _rxObject, sal_Bool _bStartListening);
- /* virtual */ ~OXReportControllerObserver(); // UNO Object must have private destructor!
-
+ virtual ~OXReportControllerObserver(); // UNO Object must have private destructor!
public:
OXReportControllerObserver(const OReportController& _rController);
diff --git a/reportdesign/source/ui/inc/metadata.hxx b/reportdesign/source/ui/inc/metadata.hxx
index a3f20f9523df..e07dce364c59 100644
--- a/reportdesign/source/ui/inc/metadata.hxx
+++ b/reportdesign/source/ui/inc/metadata.hxx
@@ -137,10 +137,10 @@ namespace rptui
#define PROPERTY_ID_DEEPTRAVERSING 25
#define PROPERTY_ID_PREEVALUATED 26
- #define PROPERTY_ID_BACKCOLOR 29
- #define PROPERTY_ID_CONTROLBACKGROUND 30
#define PROPERTY_ID_BACKTRANSPARENT 27
#define PROPERTY_ID_CONTROLBACKGROUNDTRANSPARENT 28
+ #define PROPERTY_ID_BACKCOLOR 29
+ #define PROPERTY_ID_CONTROLBACKGROUND 30
#define PROPERTY_ID_FORMULALIST 31
#define PROPERTY_ID_SCOPE 32
@@ -152,6 +152,11 @@ namespace rptui
#define PROPERTY_ID_AREA 38
#define PROPERTY_ID_MIMETYPE 39
+ #define PROPERTY_ID_FONT 40
+ #define PROPERTY_ID_PARAADJUST 41
+ #define PROPERTY_ID_VERTICALALIGN 42
+
+
//............................................................................
} // namespace rptui
//............................................................................
diff --git a/reportdesign/source/ui/inspection/DataProviderHandler.cxx b/reportdesign/source/ui/inspection/DataProviderHandler.cxx
index 66a922daeed9..3a9ebf033e03 100644
--- a/reportdesign/source/ui/inspection/DataProviderHandler.cxx
+++ b/reportdesign/source/ui/inspection/DataProviderHandler.cxx
@@ -163,9 +163,10 @@ void SAL_CALL DataProviderHandler::inspect(const uno::Reference< uno::XInterface
m_xReportComponent.set( xNameCont->getByName( ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "ReportComponent" ) ) ), uno::UNO_QUERY );
if ( m_xDataProvider.is() )
{
+ ::boost::shared_ptr<AnyConverter> aNoConverter(new AnyConverter());
TPropertyNamePair aPropertyMediation;
- aPropertyMediation.insert( TPropertyNamePair::value_type( PROPERTY_MASTERFIELDS, PROPERTY_MASTERFIELDS ) );
- aPropertyMediation.insert( TPropertyNamePair::value_type( PROPERTY_DETAILFIELDS, PROPERTY_DETAILFIELDS ) );
+ aPropertyMediation.insert( TPropertyNamePair::value_type( PROPERTY_MASTERFIELDS, TPropertyConverter(PROPERTY_MASTERFIELDS,aNoConverter) ) );
+ aPropertyMediation.insert( TPropertyNamePair::value_type( PROPERTY_DETAILFIELDS, TPropertyConverter(PROPERTY_DETAILFIELDS,aNoConverter) ) );
m_xMasterDetails = new OPropertyMediator( m_xDataProvider.get(), m_xReportComponent.get(), aPropertyMediation,sal_True );
}
@@ -488,7 +489,8 @@ void SAL_CALL DataProviderHandler::actuatingPropertyChanged(const ::rtl::OUStrin
xReceiver->setArguments( aArgs );
if ( !bModified )
xReport->setModified(sal_False);
- }
+ } // if ( NewValue != OldValue )
+ m_xFormComponentHandler->actuatingPropertyChanged(ActuatingPropertyName, NewValue, OldValue, InspectorUI, FirstTimeInit);
} // if ( ActuatingPropertyName == PROPERTY_COMMAND )
else if ( ActuatingPropertyName == PROPERTY_TITLE )
{
diff --git a/reportdesign/source/ui/inspection/GeometryHandler.cxx b/reportdesign/source/ui/inspection/GeometryHandler.cxx
index 95b7cdc3fcea..c2d9f067ff75 100644
--- a/reportdesign/source/ui/inspection/GeometryHandler.cxx
+++ b/reportdesign/source/ui/inspection/GeometryHandler.cxx
@@ -61,10 +61,11 @@
#include <com/sun/star/sdb/SQLContext.hpp>
#include <com/sun/star/sdbc/XConnection.hpp>
#include <com/sun/star/util/SearchOptions.hpp>
+#include <com/sun/star/util/MeasureUnit.hpp>
#include <com/sun/star/ui/dialogs/XExecutableDialog.hpp>
#include <com/sun/star/container/XNameContainer.hpp>
#include <com/sun/star/inspection/XNumericControl.hpp>
-#include <com/sun/star/util/MeasureUnit.hpp>
+#include <com/sun/star/style/ParagraphAdjust.hpp>
#include <vcl/msgbox.hxx>
#include <vcl/waitobj.hxx>
@@ -651,7 +652,7 @@ void SAL_CALL GeometryHandler::setPropertyValue(const ::rtl::OUString & Property
}
}
break;
- case PROPERTY_ID_CHARFONTNAME:
+ case PROPERTY_ID_FONT:
{
const uno::Reference< report::XReportControlFormat > xReportControlFormat( m_xReportComponent,uno::UNO_QUERY_THROW );
uno::Sequence< beans::NamedValue > aFontSettings;
@@ -825,7 +826,7 @@ inspection::LineDescriptor SAL_CALL GeometryHandler::describePropertyLine(const
case PROPERTY_ID_CONTROLBACKGROUND:
aOut.Control = _xControlFactory->createPropertyControl( inspection::PropertyControlType::ColorListBox, sal_False );
break;
- case PROPERTY_ID_CHARFONTNAME:
+ case PROPERTY_ID_FONT:
aOut.PrimaryButtonId = UID_RPT_RPT_PROP_DLG_FONT_TYPE;
aOut.Control = _xControlFactory->createPropertyControl( inspection::PropertyControlType::TextField, sal_True );
aOut.HasPrimaryButton = sal_True;
@@ -835,6 +836,12 @@ inspection::LineDescriptor SAL_CALL GeometryHandler::describePropertyLine(const
aOut.Control = _xControlFactory->createPropertyControl( inspection::PropertyControlType::TextField, sal_True );
aOut.HasPrimaryButton = sal_True;
break;
+ case PROPERTY_ID_VERTICALALIGN:
+ implCreateListLikeControl(_xControlFactory,aOut,RID_STR_VERTICAL_ALIGN_CONST,sal_False,sal_True);
+ break;
+ case PROPERTY_ID_PARAADJUST:
+ implCreateListLikeControl(_xControlFactory,aOut,RID_STR_PARAADJUST_CONST,sal_False,sal_True);
+ break;
default:
{
aOut = m_xFormComponentHandler->describePropertyLine(PropertyName, _xControlFactory);
@@ -1051,8 +1058,9 @@ uno::Any SAL_CALL GeometryHandler::convertToPropertyValue(const ::rtl::OUString
aPropertyValue <<= nPosX;
}
break;
- case PROPERTY_ID_CHARFONTNAME:
- return m_xFormComponentHandler->convertToPropertyValue(PROPERTY_FONTNAME, _rControlValue);
+ case PROPERTY_ID_FONT:
+ aPropertyValue = m_xFormComponentHandler->convertToPropertyValue(PROPERTY_FONT, _rControlValue);
+ break;
case PROPERTY_ID_SCOPE:
case PROPERTY_ID_FORMULALIST:
case PROPERTY_ID_AREA:
@@ -1072,6 +1080,28 @@ uno::Any SAL_CALL GeometryHandler::convertToPropertyValue(const ::rtl::OUString
case PROPERTY_ID_MIMETYPE:
aPropertyValue = _rControlValue;
break;
+ case PROPERTY_ID_VERTICALALIGN:
+ {
+ ::rtl::OUString sValue;
+ _rControlValue >>= sValue;
+ ::std::vector< ::rtl::OUString > aList;
+ tools::StringListResource aRes(ModuleRes(RID_STR_VERTICAL_ALIGN_CONST),aList);
+ ::std::vector< ::rtl::OUString >::iterator aFind = ::std::find(aList.begin(),aList.end(),sValue);
+ if ( aFind != aList.end() )
+ aPropertyValue <<= static_cast<style::VerticalAlignment>(aFind - aList.begin());
+ }
+ break;
+ case PROPERTY_ID_PARAADJUST:
+ {
+ ::rtl::OUString sValue;
+ _rControlValue >>= sValue;
+ ::std::vector< ::rtl::OUString > aList;
+ tools::StringListResource aRes(ModuleRes(RID_STR_PARAADJUST_CONST),aList);
+ ::std::vector< ::rtl::OUString >::iterator aFind = ::std::find(aList.begin(),aList.end(),sValue);
+ if ( aFind != aList.end() )
+ aPropertyValue <<= static_cast<sal_Int16>(aFind - aList.begin());
+ }
+ break;
default:
return m_xFormComponentHandler->convertToPropertyValue(PropertyName, _rControlValue);
}
@@ -1158,8 +1188,8 @@ uno::Any SAL_CALL GeometryHandler::convertToControlValue(const ::rtl::OUString &
lcl_convertFormulaTo(aPropertyValue,aControlValue);
}
break;
- case PROPERTY_ID_CHARFONTNAME:
- aControlValue = m_xFormComponentHandler->convertToControlValue(PROPERTY_FONTNAME, aPropertyValue, _rControlValueType);
+ case PROPERTY_ID_FONT:
+ aControlValue = m_xFormComponentHandler->convertToControlValue(PROPERTY_FONT, aPropertyValue, _rControlValueType);
break;
case PROPERTY_ID_POSITIONX:
{
@@ -1189,6 +1219,26 @@ uno::Any SAL_CALL GeometryHandler::convertToControlValue(const ::rtl::OUString &
aControlValue <<= aList[m_nDataFieldType];
}
break;
+ case PROPERTY_ID_VERTICALALIGN:
+ {
+ style::VerticalAlignment nParagraphVertAlign = style::VerticalAlignment_TOP;
+ aPropertyValue >>= nParagraphVertAlign;
+ ::std::vector< ::rtl::OUString > aList;
+ tools::StringListResource aRes(ModuleRes(RID_STR_VERTICAL_ALIGN_CONST),aList);
+ if ( static_cast<sal_Int16>(nParagraphVertAlign) < static_cast<sal_Int16>(aList.size()) )
+ aControlValue <<= aList[nParagraphVertAlign];
+ }
+ break;
+ case PROPERTY_ID_PARAADJUST:
+ {
+ sal_Int16 nParagraphAdjust = style::ParagraphAdjust_LEFT;
+ aPropertyValue >>= nParagraphAdjust;
+ ::std::vector< ::rtl::OUString > aList;
+ tools::StringListResource aRes(ModuleRes(RID_STR_PARAADJUST_CONST),aList);
+ if ( nParagraphAdjust < static_cast<sal_Int16>(aList.size()) )
+ aControlValue <<= aList[nParagraphAdjust];
+ }
+ break;
case PROPERTY_ID_BACKCOLOR:
case PROPERTY_ID_CONTROLBACKGROUND:
{
@@ -1249,13 +1299,15 @@ uno::Sequence< beans::Property > SAL_CALL GeometryHandler::getSupportedPropertie
,PROPERTY_INITIALFORMULA
,PROPERTY_PRESERVEIRI
,PROPERTY_DATAFIELD
- ,PROPERTY_CHARFONTNAME
+ ,PROPERTY_FONT
,PROPERTY_BACKCOLOR
,PROPERTY_BACKTRANSPARENT
,PROPERTY_CONTROLBACKGROUND
,PROPERTY_CONTROLBACKGROUNDTRANSPARENT
,PROPERTY_LABEL
,PROPERTY_MIMETYPE
+ ,PROPERTY_VERTICALALIGN
+ ,PROPERTY_PARAADJUST
};
const uno::Reference < beans::XPropertySetInfo > xInfo = m_xReportComponent->getPropertySetInfo();
const uno::Sequence< beans::Property> aSeq = xInfo->getProperties();
@@ -1346,7 +1398,7 @@ inspection::InteractiveSelectionResult SAL_CALL GeometryHandler::onInteractivePr
}
return eResult;
}
- else if ( PropertyName.equalsAscii(PROPERTY_CHARFONTNAME) )
+ else if ( PropertyName.equalsAscii(PROPERTY_FONT) )
{
::osl::ClearableMutexGuard aGuard( m_aMutex );
diff --git a/reportdesign/source/ui/inspection/inspection.src b/reportdesign/source/ui/inspection/inspection.src
index c13eb2a141c9..42d62ba94b37 100644
--- a/reportdesign/source/ui/inspection/inspection.src
+++ b/reportdesign/source/ui/inspection/inspection.src
@@ -336,6 +336,48 @@ String RID_STR_MIMETYPE
{
Text [ en-US ] = "Report Output Format" ;
};
+String RID_STR_VERTICALALIGN
+{
+ Text [ en-US ] = "Vert. Alignment" ;
+};
+Resource RID_STR_VERTICAL_ALIGN_CONST
+{
+ String 1
+ {
+ Text [ en-US ] = "Top";
+ };
+ String 2
+ {
+ Text [ en-US ] = "Middle";
+ };
+ String 3
+ {
+ Text [ en-US ] = "Bottom";
+ };
+};
+String RID_STR_PARAADJUST
+{
+ Text [ en-US ] = "Horz. Alignment" ;
+};
+Resource RID_STR_PARAADJUST_CONST
+{
+ String 1
+ {
+ Text [ en-US ] = "Left";
+ };
+ String 2
+ {
+ Text [ en-US ] = "Right";
+ };
+ String 3
+ {
+ Text [ en-US ] = "Block";
+ };
+ String 4
+ {
+ Text [ en-US ] = "Center";
+ };
+};
String RID_STR_F_COUNTER
{
Text [ en-US ] = "Counter" ;
@@ -352,3 +394,4 @@ String RID_STR_F_MAXIMUM
{
Text [ en-US ] = "Maximum" ;
};
+
diff --git a/reportdesign/source/ui/inspection/metadata.cxx b/reportdesign/source/ui/inspection/metadata.cxx
index 8c4e9a8aac00..82a19c2e1b1a 100644
--- a/reportdesign/source/ui/inspection/metadata.cxx
+++ b/reportdesign/source/ui/inspection/metadata.cxx
@@ -131,7 +131,6 @@ namespace rptui
// this ensures that we have our resource file loaded
sal_uInt16 nPos = 1;
-
static OPropertyInfoImpl aPropertyInfos[] =
{
/*
@@ -156,7 +155,7 @@ namespace rptui
,DEF_INFO_1( POSITIONY, POSITIONY, RPT_POSITIONY, COMPOSEABLE )
,DEF_INFO_1( WIDTH, WIDTH, RPT_WIDTH, COMPOSEABLE )
,DEF_INFO_1( HEIGHT, HEIGHT, RPT_HEIGHT, COMPOSEABLE )
- ,DEF_INFO_1( CHARFONTNAME, FONT, RPT_FONT, COMPOSEABLE )
+ ,DEF_INFO_1( FONT, FONT, RPT_FONT, COMPOSEABLE )
,DEF_INFO_1( PREEVALUATED, PREEVALUATED, PREEVALUATED, COMPOSEABLE )
,DEF_INFO_1( DEEPTRAVERSING, DEEPTRAVERSING, DEEPTRAVERSING, COMPOSEABLE )
,DEF_INFO_1( FORMULA, FORMULA, FORMULA, COMPOSEABLE )
@@ -177,6 +176,8 @@ namespace rptui
,DEF_INFO_2( DETAILFIELDS, DETAILFIELDS, DETAILFIELDS, COMPOSEABLE,DATA_PROPERTY)
,DEF_INFO_1( AREA, AREA, AREA, COMPOSEABLE )
,DEF_INFO_2( MIMETYPE, MIMETYPE, MIMETYPE, COMPOSEABLE,DATA_PROPERTY )
+ ,DEF_INFO_1( PARAADJUST, PARAADJUST, PARAADJUST, COMPOSEABLE )
+ ,DEF_INFO_1( VERTICALALIGN, VERTICALALIGN, VERTICALALIGN, COMPOSEABLE )
};
s_pPropertyInfos = aPropertyInfos;
@@ -298,13 +299,15 @@ namespace rptui
::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("HideInactiveSelection")),
::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("SubmitAction")),
::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("InputRequired")),
+ ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("VerticalAlign")),
+ PROPERTY_ALIGN,
PROPERTY_EMPTY_IS_NULL,
PROPERTY_FILTERPROPOSAL
,PROPERTY_POSITIONX
,PROPERTY_POSITIONY
,PROPERTY_WIDTH
,PROPERTY_HEIGHT
- ,PROPERTY_FONTNAME
+ ,PROPERTY_FONT
,PROPERTY_LABEL
,PROPERTY_LINECOLOR
,PROPERTY_BORDER
@@ -317,6 +320,7 @@ namespace rptui
,PROPERTY_SCOPE
,PROPERTY_TYPE
,PROPERTY_DATASOURCENAME
+ ,PROPERTY_VERTICALALIGN
};
beans::Property* pPropsIter = aProps.getArray();
diff --git a/reportdesign/source/ui/misc/UITools.cxx b/reportdesign/source/ui/misc/UITools.cxx
index faa4a22c8fc0..7bbdb87cc48d 100644
--- a/reportdesign/source/ui/misc/UITools.cxx
+++ b/reportdesign/source/ui/misc/UITools.cxx
@@ -99,7 +99,7 @@
#include <com/sun/star/report/XGroups.hpp>
#include <com/sun/star/awt/TextAlign.hpp>
-#include <com/sun/star/text/ParagraphVertAlign.hpp>
+#include <com/sun/star/style/VerticalAlignment.hpp>
#include <com/sun/star/report/XShape.hpp>
#include <com/sun/star/report/Function.hpp>
#include <com/sun/star/sdb/XParametersSupplier.hpp>
@@ -166,101 +166,6 @@ namespace rptui
using namespace ::com::sun::star;
using namespace formula;
// -----------------------------------------------------------------------------
-SvxCellHorJustify lcl_MapHorizontalAlignment(const sal_Int16 _nAlign)
-{
- SvxCellHorJustify eRet = SVX_HOR_JUSTIFY_STANDARD;
- switch(_nAlign)
- {
- case awt::TextAlign::LEFT:
- eRet = SVX_HOR_JUSTIFY_LEFT;
- break;
- case awt::TextAlign::CENTER:
- eRet = SVX_HOR_JUSTIFY_CENTER;
- break;
- case awt::TextAlign::RIGHT:
- eRet = SVX_HOR_JUSTIFY_RIGHT;
- break;
- default:
- OSL_ENSURE(0,"Illegal text alignment value!");
- break;
- }
- return eRet;
-}
-// -----------------------------------------------------------------------------
-sal_Int16 lcl_MapHorizontalAlignment(const SvxCellHorJustify _eAlign)
-{
- sal_Int16 nRet = awt::TextAlign::LEFT;
- switch(_eAlign)
- {
- case SVX_HOR_JUSTIFY_LEFT:
- nRet = awt::TextAlign::LEFT;
- break;
- case SVX_HOR_JUSTIFY_CENTER:
- nRet = awt::TextAlign::CENTER;
- break;
- case SVX_HOR_JUSTIFY_RIGHT:
- nRet = awt::TextAlign::RIGHT;
- break;
- case SVX_HOR_JUSTIFY_BLOCK:
- case SVX_HOR_JUSTIFY_REPEAT:
- nRet = awt::TextAlign::CENTER;
- break;
- default:
- OSL_ENSURE(0,"Illegal text alignment value!");
- break;
- }
- return nRet;
-}
-// -----------------------------------------------------------------------------
-SvxCellVerJustify lcl_MapVerticalAlignment(const sal_Int16 _nAlign)
-{
- SvxCellVerJustify eRet = SVX_VER_JUSTIFY_STANDARD;
- switch(_nAlign)
- {
- case text::ParagraphVertAlign::AUTOMATIC:
- case text::ParagraphVertAlign::BASELINE:
- eRet = SVX_VER_JUSTIFY_STANDARD;
- break;
- case text::ParagraphVertAlign::TOP:
- eRet = SVX_VER_JUSTIFY_TOP;
- break;
- case text::ParagraphVertAlign::CENTER:
- eRet = SVX_VER_JUSTIFY_CENTER;
- break;
- case text::ParagraphVertAlign::BOTTOM:
- eRet = SVX_VER_JUSTIFY_BOTTOM;
- break;
- default:
- OSL_ENSURE(0,"Illegal text alignment value!");
- break;
- }
- return eRet;
-}
-// -----------------------------------------------------------------------------
-sal_Int16 lcl_MapVerticalAlignment(const SvxCellVerJustify _eAlign)
-{
- sal_Int16 nRet = text::ParagraphVertAlign::TOP;
- switch(_eAlign)
- {
- case SVX_VER_JUSTIFY_STANDARD:
- nRet = text::ParagraphVertAlign::AUTOMATIC;
- break;
- case SVX_VER_JUSTIFY_TOP:
- nRet = text::ParagraphVertAlign::TOP;
- break;
- case SVX_VER_JUSTIFY_CENTER:
- nRet = text::ParagraphVertAlign::CENTER;
- break;
- case SVX_VER_JUSTIFY_BOTTOM:
- nRet = text::ParagraphVertAlign::BOTTOM;
- break;
- default:
- OSL_ENSURE(0,"Illegal text alignment value!");
- break;
- }
- return nRet;
-}
-// -----------------------------------------------------------------------------
void adjustSectionName(const uno::Reference< report::XGroup >& _xGroup,sal_Int32 _nPos)
{
OSL_ENSURE(_xGroup.is(),"Group is NULL -> GPF");
@@ -355,8 +260,9 @@ namespace
case COMPLEX:
aLocale = _rxReportControlFormat->getCharLocaleComplex();
break;
- }
- _rItemSet.Put(SvxLanguageItem(MsLangId::convertLocaleToLanguage(aLocale),_nLanguage));
+ } // switch(_nWhich)
+
+ _rItemSet.Put(SvxLanguageItem(MsLangId::convertLocaleToLanguageWithFallback(aLocale),_nLanguage));
_rItemSet.Put(SvxPostureItem(aFont.GetItalic(),_nPosture));
_rItemSet.Put(SvxWeightItem(aFont.GetWeight(),_nWeight));
@@ -425,6 +331,8 @@ namespace
if ( !_rxReportControlFormat.is() )
throw lang::NullPointerException();
+ uno::Reference< beans::XPropertySet > xSet(_rxReportControlFormat,uno::UNO_QUERY_THROW);
+
// fill it
const Font aFont( lcl_setFont(_rxReportControlFormat, _rItemSet,WESTERN,ITEMID_FONT,ITEMID_FONTHEIGHT,ITEMID_LANGUAGE,ITEMID_POSTURE,ITEMID_WEIGHT ) );
@@ -450,9 +358,13 @@ namespace
_rItemSet.Put(SvxCharRotateItem(_rxReportControlFormat->getCharRotation(),sal_False,ITEMID_CHARROTATE));
_rItemSet.Put(SvxCharScaleWidthItem(_rxReportControlFormat->getCharScaleWidth(),ITEMID_CHARSCALE_W));
- _rItemSet.Put(SvxHorJustifyItem(lcl_MapHorizontalAlignment(_rxReportControlFormat->getParaAdjust()),ITEMID_HORJUSTIFY));
+ SvxHorJustifyItem aHorJustifyItem(ITEMID_HORJUSTIFY);
+ aHorJustifyItem.PutValue(xSet->getPropertyValue(PROPERTY_PARAADJUST),MID_HORJUST_ADJUST);
+ _rItemSet.Put(aHorJustifyItem);
//_rItemSet.Put(SfxInt32Item(ITEMID_DEGREES,_rxReportControlFormat->getCharRotation()));
- _rItemSet.Put(SvxVerJustifyItem(lcl_MapVerticalAlignment(_rxReportControlFormat->getParaVertAlignment()),ITEMID_VERJUSTIFY));
+ SvxVerJustifyItem aVerJustifyItem(ITEMID_VERJUSTIFY);
+ aVerJustifyItem.PutValue(xSet->getPropertyValue(PROPERTY_VERTICALALIGN),0);
+ _rItemSet.Put(aVerJustifyItem);
//_rItemSet.Put(SfxInt32Item(ITEMID_IDENT,_rxReportControlFormat->getCharRotation()));
uno::Reference< report::XShape> xShape(_rxReportControlFormat,uno::UNO_QUERY);
@@ -569,12 +481,16 @@ namespace
if ( SFX_ITEM_SET == _rItemSet.GetItemState( ITEMID_HORJUSTIFY,sal_True,&pItem) && pItem->ISA(SvxHorJustifyItem))
{
const SvxHorJustifyItem* pJustifyItem = static_cast<const SvxHorJustifyItem*>(pItem);
- lcl_pushBack( _out_rProperties, PROPERTY_PARAADJUST, uno::makeAny( lcl_MapHorizontalAlignment( static_cast< SvxCellHorJustify >( pJustifyItem->GetEnumValue() ) ) ) );
+ uno::Any aValue;
+ pJustifyItem->QueryValue(aValue,MID_HORJUST_ADJUST);
+ lcl_pushBack( _out_rProperties, PROPERTY_PARAADJUST, aValue );
}
if ( SFX_ITEM_SET == _rItemSet.GetItemState( ITEMID_VERJUSTIFY,sal_True,&pItem) && pItem->ISA(SvxVerJustifyItem))
{
const SvxVerJustifyItem* pJustifyItem = static_cast<const SvxVerJustifyItem*>(pItem);
- lcl_pushBack( _out_rProperties, PROPERTY_VERTICALALIGN, uno::makeAny( lcl_MapVerticalAlignment( static_cast< SvxCellVerJustify >( pJustifyItem->GetEnumValue() ) ) ) );
+ uno::Any aValue;
+ pJustifyItem->QueryValue(aValue,0);
+ lcl_pushBack( _out_rProperties, PROPERTY_VERTICALALIGN, aValue );
}
if ( SFX_ITEM_SET == _rItemSet.GetItemState( ITEMID_CHARRELIEF,sal_True,&pItem) && pItem->ISA(SvxCharReliefItem))
{
@@ -724,7 +640,8 @@ bool openCharDialog( const uno::Reference<report::XReportControlFormat >& _rxRep
{ SID_ATTR_CHAR_SCALEWIDTH, SFX_ITEM_POOLABLE },
{ SID_ATTR_CHAR_RELIEF, SFX_ITEM_POOLABLE },
{ SID_ATTR_CHAR_HIDDEN, SFX_ITEM_POOLABLE },
- { SID_ATTR_BRUSH_CHAR, SFX_ITEM_POOLABLE },
+ //{ SID_ATTR_BRUSH_CHAR, SFX_ITEM_POOLABLE },
+ { SID_ATTR_BRUSH, SFX_ITEM_POOLABLE },
{ SID_ATTR_ALIGN_HOR_JUSTIFY, SFX_ITEM_POOLABLE },
{ SID_ATTR_ALIGN_VER_JUSTIFY, SFX_ITEM_POOLABLE },
@@ -798,19 +715,17 @@ bool openCharDialog( const uno::Reference<report::XReportControlFormat >& _rxRep
0
};
- bool bSuccess = false;
- SfxItemPool* pPool = new SfxItemPool(String::CreateFromAscii("ReportCharProperties"), ITEMID_FONT,ITEMID_WEIGHT_COMPLEX, aItemInfos, pDefaults);
+ SfxItemPool* pPool( new SfxItemPool(String::CreateFromAscii("ReportCharProperties"), ITEMID_FONT,ITEMID_WEIGHT_COMPLEX, aItemInfos, pDefaults) );
// not needed for font height pPool->SetDefaultMetric( SFX_MAPUNIT_100TH_MM ); // ripped, don't understand why
pPool->FreezeIdRanges(); // the same
-
+ bool bSuccess = false;
try
{
-
- SfxItemSet aDescriptor( *pPool, pRanges );
- lcl_CharPropertiesToItems( _rxReportControlFormat, aDescriptor );
+ ::std::auto_ptr<SfxItemSet> pDescriptor( new SfxItemSet( *pPool, pRanges ) );
+ lcl_CharPropertiesToItems( _rxReportControlFormat, *pDescriptor );
{ // want the dialog to be destroyed before our set
- ORptPageDialog aDlg(pParent, &aDescriptor, RID_PAGEDIALOG_CHAR);
+ ORptPageDialog aDlg(pParent, pDescriptor.get(),RID_PAGEDIALOG_CHAR);
uno::Reference< report::XShape > xShape( _rxReportControlFormat, uno::UNO_QUERY );
if ( xShape.is() )
aDlg.RemoveTabPage( RID_PAGE_BACKGROUND );
@@ -829,7 +744,6 @@ bool openCharDialog( const uno::Reference<report::XReportControlFormat >& _rxRep
}
SfxItemPool::Free(pPool);
-
for (sal_uInt16 i=0; i<sizeof(pDefaults)/sizeof(pDefaults[0]); ++i)
delete pDefaults[i];
@@ -856,16 +770,16 @@ bool openAreaDialog( const uno::Reference<report::XShape >& _xShape,const uno::R
try
{
SfxItemPool& rItemPool = pModel->GetItemPool();
- SfxItemSet aDescriptor( rItemPool, rItemPool.GetFirstWhich(),rItemPool.GetLastWhich() );
+ ::std::auto_ptr<SfxItemSet> pDescriptor( new SfxItemSet( rItemPool, rItemPool.GetFirstWhich(),rItemPool.GetLastWhich() ) );
- lcl_fillShapeToItems(_xShape, aDescriptor);
+ lcl_fillShapeToItems(_xShape,*pDescriptor);
{ // want the dialog to be destroyed before our set
SvxAbstractDialogFactory* pFact = SvxAbstractDialogFactory::Create();
- ::std::auto_ptr<AbstractSvxAreaTabDialog> pDialog(pFact->CreateSvxAreaTabDialog( pParent, &aDescriptor, pModel.get(), RID_SVXDLG_AREA ));
+ ::std::auto_ptr<AbstractSvxAreaTabDialog> pDialog(pFact->CreateSvxAreaTabDialog( pParent,pDescriptor.get(),pModel.get(),RID_SVXDLG_AREA ));
// #i74099# by default, the dialog deletes the current color table if a different one is loaded
// (see SwDrawShell::ExecDrawDlg)
- const SvxColorTableItem* pColorItem = static_cast<const SvxColorTableItem*>( aDescriptor.GetItem(SID_COLOR_TABLE) );
+ const SvxColorTableItem* pColorItem = static_cast<const SvxColorTableItem*>( pDescriptor->GetItem(SID_COLOR_TABLE) );
if (pColorItem && pColorItem->GetColorTable() == XColorTable::GetStdColorTable())
pDialog->DontDeleteColorTable();
bSuccess = ( RET_OK == pDialog->Execute() );
@@ -874,6 +788,7 @@ bool openAreaDialog( const uno::Reference<report::XShape >& _xShape,const uno::R
lcl_fillItemsToShape(_xShape,*pDialog->GetOutputItemSet());
}
}
+
}
catch(uno::Exception&)
{
@@ -917,7 +832,7 @@ void applyCharacterSettings( const uno::Reference< report::XReportControlFormat
lcl_applyFontAttribute( aSettings, PROPERTY_CHARCONTOURED, _rxReportControlFormat, &report::XReportControlFormat::setCharContoured );
lcl_applyFontAttribute( aSettings, PROPERTY_CHARUNDERLINECOLOR, _rxReportControlFormat, &report::XReportControlFormat::setCharUnderlineColor );
lcl_applyFontAttribute( aSettings, PROPERTY_PARAADJUST, _rxReportControlFormat, &report::XReportControlFormat::setParaAdjust );
- lcl_applyFontAttribute( aSettings, PROPERTY_VERTICALALIGN, _rxReportControlFormat, &report::XReportControlFormat::setParaVertAlignment );
+ lcl_applyFontAttribute( aSettings, PROPERTY_VERTICALALIGN, _rxReportControlFormat, &report::XReportControlFormat::setVerticalAlign );
lcl_applyFontAttribute( aSettings, PROPERTY_CHARRELIEF, _rxReportControlFormat, &report::XReportControlFormat::setCharRelief );
lcl_applyFontAttribute( aSettings, PROPERTY_CHARHIDDEN, _rxReportControlFormat, &report::XReportControlFormat::setCharHidden );
lcl_applyFontAttribute( aSettings, PROPERTY_CHARAUTOKERNING, _rxReportControlFormat, &report::XReportControlFormat::setCharAutoKerning );
diff --git a/reportdesign/source/ui/report/ReportController.cxx b/reportdesign/source/ui/report/ReportController.cxx
index 89939759abbd..777af6dd83fa 100644
--- a/reportdesign/source/ui/report/ReportController.cxx
+++ b/reportdesign/source/ui/report/ReportController.cxx
@@ -62,6 +62,7 @@
#include "reportformula.hxx"
#include <comphelper/documentconstants.hxx>
+#include <comphelper/mediadescriptor.hxx>
#include <comphelper/property.hxx>
#include <comphelper/sequenceashashmap.hxx>
#include <comphelper/types.hxx>
@@ -71,11 +72,13 @@
#include <com/sun/star/style/GraphicLocation.hpp>
#include <com/sun/star/style/XStyle.hpp>
#include <com/sun/star/style/PageStyleLayout.hpp>
+#include <com/sun/star/style/ParagraphAdjust.hpp>
#include <com/sun/star/ui/dialogs/XFilePickerControlAccess.hpp>
#include <com/sun/star/ui/dialogs/TemplateDescription.hpp>
#include <com/sun/star/ui/dialogs/ExtendedFilePickerElementIds.hpp>
#include <com/sun/star/container/XHierarchicalNameAccess.hpp>
#include <com/sun/star/frame/FrameSearchFlag.hpp>
+#include <com/sun/star/datatransfer/XTransferable.hpp>
#include <com/sun/star/container/XChild.hpp>
#include <com/sun/star/container/XNameContainer.hpp>
#include <com/sun/star/report/XImageControl.hpp>
@@ -89,6 +92,7 @@
#include <com/sun/star/sdbcx/XTablesSupplier.hpp>
#include <com/sun/star/ui/dialogs/XExecutableDialog.hpp>
#include <com/sun/star/embed/ElementModes.hpp>
+#include <com/sun/star/embed/EmbedMapUnits.hpp>
#include <comphelper/streamsection.hxx>
#include <com/sun/star/awt/FontWeight.hpp>
#include <com/sun/star/awt/FontUnderline.hpp>
@@ -160,6 +164,8 @@
#include <ReportControllerObserver.hxx>
+#define MAX_ROWS_FOR_PREVIEW 50
+
using namespace ::com::sun::star;
using namespace uno;
using namespace io;
@@ -306,6 +312,7 @@ OReportController::OReportController(Reference< XComponentContext > const & xCon
,m_bHelplinesMove(sal_True)
,m_bChartEnabled(false)
,m_bChartEnabledAsked(false)
+,m_bInGeneratePreview(false)
{
// new Observer
m_pReportControllerObserver = new OXReportControllerObserver(*this);
@@ -850,6 +857,7 @@ FeatureState OReportController::GetState(sal_uInt16 _nId) const
case SID_ATTR_PARA_ADJUST_LEFT:
case SID_ATTR_PARA_ADJUST_CENTER:
case SID_ATTR_PARA_ADJUST_RIGHT:
+ case SID_ATTR_PARA_ADJUST_BLOCK:
impl_fillState_nothrow(PROPERTY_PARAADJUST,aReturn);
if ( aReturn.bEnabled )
{
@@ -858,15 +866,19 @@ FeatureState OReportController::GetState(sal_uInt16 _nId) const
{
switch(nParaAdjust)
{
- case awt::TextAlign::LEFT:
+ case style::ParagraphAdjust_LEFT:
aReturn.bChecked = _nId == SID_ATTR_PARA_ADJUST_LEFT;
break;
- case awt::TextAlign::CENTER:
- aReturn.bChecked = _nId == SID_ATTR_PARA_ADJUST_CENTER;
- break;
- case awt::TextAlign::RIGHT:
+ case style::ParagraphAdjust_RIGHT:
aReturn.bChecked = _nId == SID_ATTR_PARA_ADJUST_RIGHT;
break;
+ case style::ParagraphAdjust_BLOCK:
+ case style::ParagraphAdjust_STRETCH:
+ aReturn.bChecked = _nId == SID_ATTR_PARA_ADJUST_BLOCK;
+ break;
+ case style::ParagraphAdjust_CENTER:
+ aReturn.bChecked = _nId == SID_ATTR_PARA_ADJUST_CENTER;
+ break;
}
} // if ( aReturn.aValue >>= nParaAdjust )
aReturn.aValue.clear();
@@ -1505,25 +1517,30 @@ void OReportController::Execute(sal_uInt16 _nId, const Sequence< PropertyValue >
case SID_ATTR_PARA_ADJUST_LEFT:
case SID_ATTR_PARA_ADJUST_CENTER:
case SID_ATTR_PARA_ADJUST_RIGHT:
+ case SID_ATTR_PARA_ADJUST_BLOCK:
{
- sal_Int16 nValue = awt::TextAlign::LEFT;
+ sal_Int16 eParagraphAdjust = style::ParagraphAdjust_LEFT;
switch(_nId)
{
case SID_ATTR_PARA_ADJUST_LEFT:
- nValue = awt::TextAlign::LEFT;
+ eParagraphAdjust = style::ParagraphAdjust_LEFT;
break;
case SID_ATTR_PARA_ADJUST_CENTER:
- nValue = awt::TextAlign::CENTER;
+ eParagraphAdjust = style::ParagraphAdjust_CENTER;
break;
case SID_ATTR_PARA_ADJUST_RIGHT:
- nValue = awt::TextAlign::RIGHT;
+ eParagraphAdjust = style::ParagraphAdjust_RIGHT;
+ break;
+ case SID_ATTR_PARA_ADJUST_BLOCK:
+ eParagraphAdjust = style::ParagraphAdjust_BLOCK;
break;
} // switch(_nId)
- impl_setPropertyAtControls_throw(RID_STR_UNDO_ALIGNMENT,PROPERTY_PARAADJUST,uno::makeAny(nValue),aArgs);
+ impl_setPropertyAtControls_throw(RID_STR_UNDO_ALIGNMENT,PROPERTY_PARAADJUST,uno::makeAny(eParagraphAdjust),aArgs);
InvalidateFeature(SID_ATTR_PARA_ADJUST_LEFT);
InvalidateFeature(SID_ATTR_PARA_ADJUST_CENTER);
InvalidateFeature(SID_ATTR_PARA_ADJUST_RIGHT);
+ InvalidateFeature(SID_ATTR_PARA_ADJUST_BLOCK);
}
break;
case SID_CHAR_DLG:
@@ -1686,7 +1703,11 @@ void OReportController::impl_initialize( )
m_xFormatter.set(getORB()->createInstance(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.util.NumberFormatter"))), UNO_QUERY);
m_xFormatter->attachNumberFormatsSupplier(Reference< XNumberFormatsSupplier>(m_xReportDefinition,uno::UNO_QUERY));
- if ( !m_xReportDefinition->getCommand().getLength() && getConnection().is())
+ ::comphelper::MediaDescriptor aDescriptor( m_xReportDefinition->getArgs() );
+ ::rtl::OUString sHierarchicalDocumentName;
+ sHierarchicalDocumentName = aDescriptor.getUnpackedValueOrDefault(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("HierarchicalDocumentName")),sHierarchicalDocumentName);
+
+ if ( !sHierarchicalDocumentName.getLength() && getConnection().is() )
{
uno::Reference<sdbcx::XTablesSupplier> xTablesSup(getConnection(),uno::UNO_QUERY_THROW);
uno::Reference<container::XNameAccess> xTables = xTablesSup->getTables();
@@ -1866,6 +1887,8 @@ void OReportController::describeSupportedFeatures()
implDescribeSupportedFeature( ".uno:LeftPara", SID_ATTR_PARA_ADJUST_LEFT, CommandGroup::FORMAT );
implDescribeSupportedFeature( ".uno:CenterPara", SID_ATTR_PARA_ADJUST_CENTER, CommandGroup::FORMAT );
implDescribeSupportedFeature( ".uno:RightPara", SID_ATTR_PARA_ADJUST_RIGHT, CommandGroup::FORMAT );
+ implDescribeSupportedFeature( ".uno:JustifyPara", SID_ATTR_PARA_ADJUST_BLOCK, CommandGroup::FORMAT );
+
implDescribeSupportedFeature( ".uno:FontHeight", SID_ATTR_CHAR_FONTHEIGHT, CommandGroup::FORMAT );
implDescribeSupportedFeature( ".uno:CharFontName", SID_ATTR_CHAR_FONT, CommandGroup::FORMAT );
@@ -2418,26 +2441,24 @@ void OReportController::openPageDialog(const uno::Reference<report::XSection>& _
SID_ATTR_METRIC,SID_ATTR_METRIC,
0
};
-
- SfxItemPool* pPool = new SfxItemPool(String::CreateFromAscii("ReportPageProperties"), RPTUI_ID_LRSPACE,RPTUI_ID_METRIC, aItemInfos, pDefaults);
+ SfxItemPool* pPool( new SfxItemPool(String::CreateFromAscii("ReportPageProperties"), RPTUI_ID_LRSPACE,RPTUI_ID_METRIC, aItemInfos, pDefaults) );
pPool->SetDefaultMetric( SFX_MAPUNIT_100TH_MM ); // ripped, don't understand why
pPool->FreezeIdRanges(); // the same
try
{
- SfxItemSet aDescriptor(*pPool, pRanges);
-
+ ::std::auto_ptr<SfxItemSet> pDescriptor(new SfxItemSet(*pPool, pRanges));
// fill it
if ( _xSection.is() )
- aDescriptor.Put(SvxBrushItem(::Color(_xSection->getBackColor()),ITEMID_BRUSH));
+ pDescriptor->Put(SvxBrushItem(::Color(_xSection->getBackColor()),ITEMID_BRUSH));
else
{
- aDescriptor.Put(SvxSizeItem(RPTUI_ID_SIZE,VCLSize(getStyleProperty<awt::Size>(m_xReportDefinition,PROPERTY_PAPERSIZE))));
- aDescriptor.Put(SvxLRSpaceItem(getStyleProperty<sal_Int32>(m_xReportDefinition,PROPERTY_LEFTMARGIN)
+ pDescriptor->Put(SvxSizeItem(RPTUI_ID_SIZE,VCLSize(getStyleProperty<awt::Size>(m_xReportDefinition,PROPERTY_PAPERSIZE))));
+ pDescriptor->Put(SvxLRSpaceItem(getStyleProperty<sal_Int32>(m_xReportDefinition,PROPERTY_LEFTMARGIN)
,getStyleProperty<sal_Int32>(m_xReportDefinition,PROPERTY_RIGHTMARGIN),0,0,RPTUI_ID_LRSPACE));
- aDescriptor.Put(SvxULSpaceItem(static_cast<USHORT>(getStyleProperty<sal_Int32>(m_xReportDefinition,PROPERTY_TOPMARGIN))
+ pDescriptor->Put(SvxULSpaceItem(static_cast<USHORT>(getStyleProperty<sal_Int32>(m_xReportDefinition,PROPERTY_TOPMARGIN))
,static_cast<USHORT>(getStyleProperty<sal_Int32>(m_xReportDefinition,PROPERTY_BOTTOMMARGIN)),RPTUI_ID_ULSPACE));
- aDescriptor.Put(SfxUInt16Item(SID_ATTR_METRIC,static_cast<UINT16>(eUserMetric)));
+ pDescriptor->Put(SfxUInt16Item(SID_ATTR_METRIC,static_cast<UINT16>(eUserMetric)));
uno::Reference< style::XStyle> xPageStyle(getUsedStyle(m_xReportDefinition));
if ( xPageStyle.is() )
@@ -2448,13 +2469,13 @@ void OReportController::openPageDialog(const uno::Reference<report::XSection>& _
aPageItem.PutValue(xProp->getPropertyValue(PROPERTY_PAGESTYLELAYOUT),MID_PAGE_LAYOUT);
aPageItem.SetLandscape(getStyleProperty<sal_Bool>(m_xReportDefinition,PROPERTY_ISLANDSCAPE));
aPageItem.SetNumType((SvxNumType)getStyleProperty<sal_Int16>(m_xReportDefinition,PROPERTY_NUMBERINGTYPE));
- aDescriptor.Put(aPageItem);
- aDescriptor.Put(SvxBrushItem(::Color(getStyleProperty<sal_Int32>(m_xReportDefinition,PROPERTY_BACKCOLOR)),RPTUI_ID_BRUSH));
+ pDescriptor->Put(aPageItem);
+ pDescriptor->Put(SvxBrushItem(::Color(getStyleProperty<sal_Int32>(m_xReportDefinition,PROPERTY_BACKCOLOR)),RPTUI_ID_BRUSH));
}
}
{ // want the dialog to be destroyed before our set
- ORptPageDialog aDlg(getView(), &aDescriptor, _xSection.is() ? RID_PAGEDIALOG_BACKGROUND : RID_PAGEDIALOG_PAGE);
+ ORptPageDialog aDlg(getView(), pDescriptor.get(),_xSection.is() ? RID_PAGEDIALOG_BACKGROUND : RID_PAGEDIALOG_PAGE);
if (RET_OK == aDlg.Execute())
{
// ------------
@@ -2516,11 +2537,11 @@ void OReportController::openPageDialog(const uno::Reference<report::XSection>& _
{
DBG_UNHANDLED_EXCEPTION();
}
-
SfxItemPool::Free(pPool);
for (sal_uInt16 i=0; i<sizeof(pDefaults)/sizeof(pDefaults[0]); ++i)
delete pDefaults[i];
+
}
// -----------------------------------------------------------------------------
sal_Bool SAL_CALL OReportController::attachModel(const uno::Reference< frame::XModel > & xModel) throw( uno::RuntimeException )
@@ -2895,6 +2916,7 @@ uno::Reference<frame::XModel> OReportController::executeReport()
}
else
{
+ m_bInGeneratePreview = true;
try
{
WaitObject aWait(getView()); // cursor
@@ -2943,7 +2965,8 @@ uno::Reference<frame::XModel> OReportController::executeReport()
{
const String suSQLContext = String( ModuleRes( RID_STR_COULD_NOT_CREATE_REPORT ) );
aInfo.prepend(suSQLContext);
- }
+ } // if (aInfo.isValid())
+ m_bInGeneratePreview = false;
}
if (aInfo.isValid())
@@ -2975,11 +2998,12 @@ uno::Reference< sdbc::XRowSet > OReportController::getRowSet()
xRowSetProp->setPropertyValue( PROPERTY_ACTIVECONNECTION, uno::makeAny( getConnection() ) );
xRowSetProp->setPropertyValue( PROPERTY_APPLYFILTER, uno::makeAny( sal_True ) );
+ ::boost::shared_ptr<AnyConverter> aNoConverter(new AnyConverter());
TPropertyNamePair aPropertyMediation;
- aPropertyMediation.insert( TPropertyNamePair::value_type( PROPERTY_COMMAND, PROPERTY_COMMAND ) );
- aPropertyMediation.insert( TPropertyNamePair::value_type( PROPERTY_COMMANDTYPE, PROPERTY_COMMANDTYPE ) );
- aPropertyMediation.insert( TPropertyNamePair::value_type( PROPERTY_ESCAPEPROCESSING, PROPERTY_ESCAPEPROCESSING ) );
- aPropertyMediation.insert( TPropertyNamePair::value_type( PROPERTY_FILTER, PROPERTY_FILTER ) );
+ aPropertyMediation.insert( TPropertyNamePair::value_type( PROPERTY_COMMAND, TPropertyConverter(PROPERTY_COMMAND,aNoConverter) ) );
+ aPropertyMediation.insert( TPropertyNamePair::value_type( PROPERTY_COMMANDTYPE, TPropertyConverter(PROPERTY_COMMANDTYPE,aNoConverter) ) );
+ aPropertyMediation.insert( TPropertyNamePair::value_type( PROPERTY_ESCAPEPROCESSING, TPropertyConverter(PROPERTY_ESCAPEPROCESSING,aNoConverter) ) );
+ aPropertyMediation.insert( TPropertyNamePair::value_type( PROPERTY_FILTER, TPropertyConverter(PROPERTY_FILTER,aNoConverter) ) );
m_xRowSetMediator = new OPropertyMediator( m_xReportDefinition.get(), xRowSetProp, aPropertyMediation );
m_xRowSet = xRowSet;
@@ -4221,21 +4245,18 @@ void OReportController::openZoomDialog()
SID_ATTR_ZOOM,SID_ATTR_ZOOM,
0
};
-
- SfxItemPool* pPool = new SfxItemPool(String::CreateFromAscii("ZoomProperties"), SID_ATTR_ZOOM,SID_ATTR_ZOOM, aItemInfos, pDefaults);
+ SfxItemPool* pPool( new SfxItemPool(String::CreateFromAscii("ZoomProperties"), SID_ATTR_ZOOM,SID_ATTR_ZOOM, aItemInfos, pDefaults) );
pPool->SetDefaultMetric( SFX_MAPUNIT_100TH_MM ); // ripped, don't understand why
pPool->FreezeIdRanges(); // the same
-
try
{
- SfxItemSet aDescriptor(*pPool, pRanges);
-
+ ::std::auto_ptr<SfxItemSet> pDescriptor(new SfxItemSet(*pPool, pRanges));
// fill it
SvxZoomItem aZoomItem( m_eZoomType, m_nZoomValue, SID_ATTR_ZOOM );
aZoomItem.SetValueSet(SVX_ZOOM_ENABLE_100|SVX_ZOOM_ENABLE_WHOLEPAGE|SVX_ZOOM_ENABLE_PAGEWIDTH);
- aDescriptor.Put(aZoomItem);
+ pDescriptor->Put(aZoomItem);
- ::std::auto_ptr<AbstractSvxZoomDialog> pDlg( pFact->CreateSvxZoomDialog(NULL, aDescriptor, RID_SVXDLG_ZOOM) );
+ ::std::auto_ptr<AbstractSvxZoomDialog> pDlg( pFact->CreateSvxZoomDialog(NULL, *pDescriptor.get(), RID_SVXDLG_ZOOM) );
pDlg->SetLimits( 20, 400 );
bool bCancel = ( RET_CANCEL == pDlg->Execute() );
@@ -4254,7 +4275,6 @@ void OReportController::openZoomDialog()
{
DBG_UNHANDLED_EXCEPTION();
}
-
SfxItemPool::Free(pPool);
for (sal_uInt16 i=0; i<sizeof(pDefaults)/sizeof(pDefaults[0]); ++i)
@@ -4262,3 +4282,70 @@ void OReportController::openZoomDialog()
} // if(pFact)
}
// -----------------------------------------------------------------------------
+// -----------------------------------------------------------------------------
+// XVisualObject
+void SAL_CALL OReportController::setVisualAreaSize( ::sal_Int64 _nAspect, const awt::Size& _aSize ) throw (lang::IllegalArgumentException, embed::WrongStateException, uno::Exception, uno::RuntimeException)
+{
+ ::osl::MutexGuard aGuard( getMutex() );
+ //if( nAspect == embed::Aspects::MSOLE_CONTENT )
+ {
+ bool bChanged =
+ (m_aVisualAreaSize.Width != _aSize.Width ||
+ m_aVisualAreaSize.Height != _aSize.Height);
+ m_aVisualAreaSize = _aSize;
+ if( bChanged )
+ setModified( sal_True );
+ }
+ m_nAspect = _nAspect;
+}
+// -----------------------------------------------------------------------------
+awt::Size SAL_CALL OReportController::getVisualAreaSize( ::sal_Int64 /*nAspect*/ ) throw (lang::IllegalArgumentException, embed::WrongStateException, uno::Exception, uno::RuntimeException)
+{
+ ::osl::MutexGuard aGuard( getMutex() );
+ return m_aVisualAreaSize;
+}
+// -----------------------------------------------------------------------------
+embed::VisualRepresentation SAL_CALL OReportController::getPreferredVisualRepresentation( ::sal_Int64 _nAspect ) throw (lang::IllegalArgumentException, embed::WrongStateException, uno::Exception, uno::RuntimeException)
+{
+ ::vos::OGuard aSolarGuard( Application::GetSolarMutex() );
+ ::osl::MutexGuard aGuard( getMutex() );
+ embed::VisualRepresentation aResult;
+ if ( !m_bInGeneratePreview )
+ {
+ m_bInGeneratePreview = true;
+ try
+ {
+ if ( !m_xReportEngine.is() )
+ m_xReportEngine.set(getORB()->createInstance(SERVICE_REPORTENGINE),uno::UNO_QUERY_THROW);
+ const sal_Int32 nOldMaxRows = m_xReportEngine->getMaxRows();
+ m_xReportEngine->setMaxRows(MAX_ROWS_FOR_PREVIEW);
+ m_xReportEngine->setReportDefinition(m_xReportDefinition);
+ m_xReportEngine->setActiveConnection(getConnection());
+ try
+ {
+ Reference<embed::XVisualObject> xTransfer(m_xReportEngine->createDocumentModel(),UNO_QUERY);
+ if ( xTransfer.is() )
+ {
+ xTransfer->setVisualAreaSize(m_nAspect,m_aVisualAreaSize);
+ aResult = xTransfer->getPreferredVisualRepresentation( _nAspect );
+ } // if ( xTransfer.is() )
+ }
+ catch( uno::Exception & ex )
+ {
+ (void)ex;
+ }
+ m_xReportEngine->setMaxRows(nOldMaxRows);
+ }
+ catch( uno::Exception & ex )
+ {
+ (void)ex;
+ }
+ m_bInGeneratePreview = false;
+ }
+ return aResult;
+}
+// -----------------------------------------------------------------------------
+::sal_Int32 SAL_CALL OReportController::getMapUnit( ::sal_Int64 /*nAspect*/ ) throw (uno::Exception, uno::RuntimeException)
+{
+ return embed::EmbedMapUnits::ONE_100TH_MM;
+}
diff --git a/reportdesign/source/ui/report/ViewsWindow.cxx b/reportdesign/source/ui/report/ViewsWindow.cxx
index 42ceaaea5eba..aebf42bfaa00 100644
--- a/reportdesign/source/ui/report/ViewsWindow.cxx
+++ b/reportdesign/source/ui/report/ViewsWindow.cxx
@@ -1104,7 +1104,9 @@ void OViewsWindow::BegDragObj_createInvisibleObjectAtPosition(const Rectangle& _
// pNewObj->Move(Size(_aRect.Left(), _aRect.Top()));
pNewObj->Move(Size(0, aNewPos.Y()));
+ BOOL bChanged = rView.GetModel()->IsChanged();
rReportSection.getPage()->InsertObject(pNewObj);
+ rView.GetModel()->SetChanged(bChanged);
m_aBegDragTempList.push_back(pNewObj);
Rectangle aRect = pNewObj->GetLogicRect();
@@ -1120,16 +1122,7 @@ void OViewsWindow::BegDragObj_createInvisibleObjectAtPosition(const Rectangle& _
// -----------------------------------------------------------------------------
bool OViewsWindow::isObjectInMyTempList(SdrObject *_pObj)
{
- ::std::vector<SdrObject*>::iterator aIter = m_aBegDragTempList.begin();
- ::std::vector<SdrObject*>::iterator aEnd = m_aBegDragTempList.end();
- for (; aIter != aEnd; ++aIter)
- {
- if (*aIter == _pObj)
- {
- return true;
- }
- }
- return false;
+ return ::std::find(m_aBegDragTempList.begin(),m_aBegDragTempList.end(),_pObj) != m_aBegDragTempList.end();
}
// -----------------------------------------------------------------------------
@@ -1552,7 +1545,6 @@ void OViewsWindow::MovAction(const Point& _aPnt,const OSectionView* _pSection,bo
const long nSectionHeight = (*aIter)->PixelToLogic((*aIter)->GetOutputSizePixel()).Height();
aRealMousePos.Y() -= nSectionHeight;
}
-
#if 0
#if OSL_DEBUG_LEVEL > 0
// TEST TEST TEST TEST
diff --git a/reportdesign/source/ui/report/propbrw.cxx b/reportdesign/source/ui/report/propbrw.cxx
index 3b8dd3616ee5..111cc936ace3 100644
--- a/reportdesign/source/ui/report/propbrw.cxx
+++ b/reportdesign/source/ui/report/propbrw.cxx
@@ -446,6 +446,7 @@ void PropBrw::implSetNewObject( const uno::Sequence< Reference<uno::XInterface>
// -----------------------------------------------------------------------------
uno::Reference< uno::XInterface> PropBrw::CreateComponentPair(OObjectBase* _pObj)
{
+ _pObj->initializeOle();
return CreateComponentPair(_pObj->getAwtComponent(),_pObj->getReportComponent());
}
//----------------------------------------------------------------------------
diff --git a/reportdesign/uiconfig/dbreport/menubar/menubar.xml b/reportdesign/uiconfig/dbreport/menubar/menubar.xml
index a8c8d2e0d871..8fa04f47ba7f 100644
--- a/reportdesign/uiconfig/dbreport/menubar/menubar.xml
+++ b/reportdesign/uiconfig/dbreport/menubar/menubar.xml
@@ -37,7 +37,6 @@
<menu:menuitem menu:id=".uno:SelectAllLabels"/>
<menu:menuitem menu:id=".uno:SelectAllEdits"/>
<menu:menuitem menu:id=".uno:SelectReport"/>
- <menu:menuitem menu:id=".uno:SelectObject"/>
</menu:menupopup>
</menu:menu>
<menu:menuseparator/>
@@ -47,6 +46,74 @@
<menu:menuitem menu:id=".uno:ReportHeaderFooter"/>
<menu:menuitem menu:id=".uno:ColumnHeaderFooter"/>
<menu:menuseparator/>
+
+ <menu:menu menu:id=".uno:EditShapeMenu">
+ <menu:menupopup>
+ <!--
+ <menu:menu menu:id=".uno:ArrangeMenu">
+ <menu:menupopup>
+-->
+ <menu:menuitem menu:id=".uno:BringToFront"/>
+ <menu:menuitem menu:id=".uno:ObjectBackOne"/>
+ <menu:menuitem menu:id=".uno:ObjectForwardOne"/>
+ <menu:menuitem menu:id=".uno:SendToBack"/>
+ <menu:menuseparator/>
+ <menu:menuitem menu:id=".uno:SetObjectToForeground"/>
+ <menu:menuitem menu:id=".uno:SetObjectToBackground"/>
+ <!--
+ </menu:menupopup>
+ </menu:menu>
+-->
+ </menu:menupopup>
+ </menu:menu>
+
+ <menu:menu menu:id=".uno:EditControlMenu">
+ <menu:menupopup>
+ <menu:menu menu:id=".uno:ObjectAlign" >
+ <menu:menupopup>
+ <menu:menuitem menu:id=".uno:ObjectAlignLeft"/>
+ <menu:menuitem menu:id=".uno:AlignCenter"/>
+ <menu:menuitem menu:id=".uno:ObjectAlignRight"/>
+ <menu:menuseparator/>
+ <menu:menuitem menu:id=".uno:AlignUp"/>
+ <menu:menuitem menu:id=".uno:AlignMiddle"/>
+ <menu:menuitem menu:id=".uno:AlignDown"/>
+ </menu:menupopup>
+ </menu:menu>
+
+ <menu:menu menu:id=".uno:ObjectResize" >
+ <menu:menupopup>
+ <menu:menuitem menu:id=".uno:SmallestWidth"/>
+ <menu:menuitem menu:id=".uno:GreatestWidth"/>
+ <menu:menuseparator/>
+ <menu:menuitem menu:id=".uno:SmallestHeight"/>
+ <menu:menuitem menu:id=".uno:GreatestHeight"/>
+ </menu:menupopup>
+ </menu:menu>
+
+ <menu:menu menu:id=".uno:SectionAlignmentMenu" >
+ <menu:menupopup>
+ <menu:menuitem menu:id=".uno:SectionAlignLeft"/>
+ <menu:menuitem menu:id=".uno:SectionAlignRight"/>
+ <menu:menuseparator/>
+ <menu:menuitem menu:id=".uno:SectionAlignTop"/>
+ <menu:menuitem menu:id=".uno:SectionAlignBottom"/>
+ </menu:menupopup>
+ </menu:menu>
+
+ </menu:menupopup>
+ </menu:menu>
+
+ <menu:menu menu:id=".uno:SectionShrinkMenu" >
+ <menu:menupopup>
+ <menu:menuitem menu:id=".uno:SectionShrink"/>
+ <menu:menuitem menu:id=".uno:SectionShrinkTop"/>
+ <menu:menuitem menu:id=".uno:SectionShrinkBottom"/>
+ </menu:menupopup>
+ </menu:menu>
+
+
+ <menu:menuseparator/>
<menu:menuitem menu:id=".uno:ExecuteReport"/>
</menu:menupopup>
</menu:menu>
@@ -85,6 +152,10 @@
<menu:menuseparator/>
<menu:menu menu:id=".uno:ReportControlMenu" >
<menu:menupopup>
+ <menu:menuitem menu:id=".uno:SelectObject"/>
+ <menu:menuseparator/>
+ <menu:menuitem menu:id=".uno:ControlProperties"/>
+ <menu:menuseparator/>
<menu:menuitem menu:id=".uno:Label" />
<menu:menuitem menu:id=".uno:Edit" />
<menu:menuitem menu:id=".uno:ImageControl" />
@@ -304,23 +375,6 @@
<menu:menuitem menu:id=".uno:GreatestHeight"/>
</menu:menupopup>
</menu:menu>
- <menu:menu menu:id=".uno:SectionAlignmentMenu" >
- <menu:menupopup>
- <menu:menuitem menu:id=".uno:SectionAlignLeft"/>
- <menu:menuitem menu:id=".uno:SectionAlignRight"/>
- <menu:menuseparator/>
- <menu:menuitem menu:id=".uno:SectionAlignTop"/>
- <menu:menuitem menu:id=".uno:SectionAlignBottom"/>
- </menu:menupopup>
- </menu:menu>
- <menu:menuseparator/>
- <menu:menu menu:id=".uno:SectionShrinkMenu" >
- <menu:menupopup>
- <menu:menuitem menu:id=".uno:SectionShrink"/>
- <menu:menuitem menu:id=".uno:SectionShrinkTop"/>
- <menu:menuitem menu:id=".uno:SectionShrinkBottom"/>
- </menu:menupopup>
- </menu:menu>
<menu:menuseparator/>
<menu:menuitem menu:id=".uno:Distribution"/>
</menu:menupopup>
diff --git a/reportdesign/uiconfig/dbreport/toolbar/Formatting.xml b/reportdesign/uiconfig/dbreport/toolbar/Formatting.xml
index c4fe386324a7..2fc8494938d4 100644
--- a/reportdesign/uiconfig/dbreport/toolbar/Formatting.xml
+++ b/reportdesign/uiconfig/dbreport/toolbar/Formatting.xml
@@ -14,6 +14,7 @@
<toolbar:toolbaritem xlink:href=".uno:LeftPara" toolbar:style="radio" />
<toolbar:toolbaritem xlink:href=".uno:CenterPara" toolbar:style="radio" />
<toolbar:toolbaritem xlink:href=".uno:RightPara" toolbar:style="radio" />
+ <toolbar:toolbaritem xlink:href=".uno:JustifyPara" toolbar:helpid="helpid:10031" toolbar:text="" toolbar:style="radio" />
<toolbar:toolbarseparator/>
<toolbar:toolbaritem xlink:href=".uno:FontColor" toolbar:style="dropdown" />
<toolbar:toolbaritem xlink:href=".uno:BackgroundColor" toolbar:style="dropdown" />
diff --git a/reportdesign/util/hidother.src b/reportdesign/util/hidother.src
index f0b1e8d5aa72..15cc051a5193 100644
--- a/reportdesign/util/hidother.src
+++ b/reportdesign/util/hidother.src
@@ -165,8 +165,10 @@ hidspecial HID_RPT_PROP_AREA { HelpId = HID_RPT_PROP_AREA; };
hidspecial UID_RPT_RPT_PROP_DLG_AREA { HelpId = UID_RPT_RPT_PROP_DLG_AREA; };
hidspecial UID_RPT_PROP_FORMULA { HelpId = UID_RPT_PROP_FORMULA; };
-hidspecial HID_RPT_GROUPSORT_MOVE_UP { HelpId = HID_RPT_GROUPSORT_MOVE_UP; };
-hidspecial HID_RPT_GROUPSORT_MOVE_DOWN { HelpId = HID_RPT_GROUPSORT_MOVE_DOWN; };
-hidspecial HID_RPT_GROUPSORT_DELETE { HelpId = HID_RPT_GROUPSORT_DELETE; };
-hidspecial HID_RPT_PROP_MIMETYPE { HelpId = HID_RPT_PROP_MIMETYPE; };
+hidspecial HID_RPT_GROUPSORT_MOVE_UP { HelpId = HID_RPT_GROUPSORT_MOVE_UP; };
+hidspecial HID_RPT_GROUPSORT_MOVE_DOWN { HelpId = HID_RPT_GROUPSORT_MOVE_DOWN; };
+hidspecial HID_RPT_GROUPSORT_DELETE { HelpId = HID_RPT_GROUPSORT_DELETE; };
+hidspecial HID_RPT_PROP_MIMETYPE { HelpId = HID_RPT_PROP_MIMETYPE; };
+hidspecial HID_RPT_PROP_VERTICALALIGN { HelpId = HID_RPT_PROP_VERTICALALIGN; };
+hidspecial HID_RPT_PROP_PARAADJUST { HelpId = HID_RPT_PROP_PARAADJUST; };