Commit Graph

5400 Commits

Author SHA1 Message Date
Markus Mohrhard
ed24ae433b prevent that early return prevents further user interaction
Change-Id: I24f814a402d2b8af3ddf888719b78d3158c2a38f
2014-05-27 16:56:03 +02:00
Michael Meeks
8c9b3cdcce cache the bitmap converted to flat RGBA pixels.
Conflicts:
	chart2/source/view/inc/3DChartObjects.hxx
	chart2/source/view/main/3DChartObjects.cxx

Change-Id: Ied38d4457fbc04ded42fe4fb55a8ec654cefa259
2014-05-27 16:56:03 +02:00
Maxim Monastirsky
209eea5457 chart2: Fix using the last shape
Clicking a shape button works only for the default shape,
not for the last used one.

Steps to reproduce:
1) Click on the drop-down arrow of one of the shape buttons,
   and select a shape. Notice that the button icon updates
   with the last selected shape.
2) Click on another button.
3) Click on the first button, and try to draw something.
   The button doesn't work anymore. Only opening the sub
   toolbar and selecting the shape there will work.

The problem is in ToolboxController::execute that requires
the command to be in the listener map, but we didn't
register sub commands (like .uno:SymbolShapes.sun).
Instead of doing that, we'll try some generic solution.
(Note that calling the corresponding method from
SvxTbxCtlCustomShapes like we do in other methods here
won't work, because ChartController::queryDispatch checks
for the "_self" target, but SfxToolBoxControl::Dispatch
doesn't provide it.)

Change-Id: I5be3dfd3ee3ca9ab9d8080929173dbe5984f61a0
2014-05-27 17:23:35 +03:00
Thomas Arnhold
92b447876d css already means ::com::sun::star
Change-Id: I48d7b746d7cc49246743c62480b0d225d2519342
2014-05-27 14:00:28 +02:00
Peter Senna Tschudin
3b24dcc8a8 Remove unnecessary semicolons
A simplified version of the semantic match that finds this problem is
follows: (http://coccinelle.lip6.fr/)

// <smpl>
@r1@
statement S;
position p,p1;
@@
S@p1;@p

@script:python r2@
p << r1.p;
p1 << r1.p1;
@@
if p[0].line != p1[0].line_end:
    cocci.include_match(False)
@@
position r1.p;
@@
-;@p
// </smpl>

Change-Id: Ib9708d37fbb4c6060f88d5dae3814a2d37b2091e
Reviewed-on: https://gerrit.libreoffice.org/9493
Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
Tested-by: Noel Grandin <noelgrandin@gmail.com>
2014-05-27 01:19:00 -05:00
Fridrich Štrba
7da3ce7cdb Allow building with more recent glm versions
Use glm::scale(glm::vec3(x, y, z)) instead of glm::scale(x, y, z)

Change-Id: Id307b830c0ee6cf69514e117ee1e3811a65f8bfd
2014-05-26 23:25:47 +02:00
Markus Mohrhard
25cea66f6a remove unused variables
Change-Id: Ia94a501fa2571752286df0451a0a8a2b303a10c8
2014-05-26 22:50:36 +02:00
Markus Mohrhard
e69e429d8f hardcode default camera height
instead of having the magic number in 5 places

Change-Id: I2550671572dcc36d9a710e56d9d9c1e99f732843
2014-05-26 22:50:35 +02:00
Markus Mohrhard
3c5392997d switch the direction of the series labels
Change-Id: I718ee4782a8b1e265131f6e4e02093a59c17cb15
2014-05-26 22:50:35 +02:00
Markus Mohrhard
3bc86e1c92 use the center of the chart as camera direction
Change-Id: I943273817a26235afd9f17e55d2ee14c5f94c409
2014-05-26 22:50:35 +02:00
Noel Grandin
727ea1e4dd fix spelling of "indices"
Change-Id: I6dc8960d776b809aa701bf8e554e96131b6440c9
2014-05-26 14:47:32 +02:00
Noel Grandin
7a0069b2e2 cid#1213562 Uninitialized scalar field
Change-Id: Ieec390aa1af1af53f375d707b920382f7a994fc1
2014-05-26 14:47:32 +02:00
Stephan Bergmann
7686f93f58 loplugin:unreffun
Change-Id: I43133e272fc915363b178d5f13377c9210eb628e
2014-05-26 07:47:17 +02:00
Markus Mohrhard
dc91ebed1a react only to left mouse click
Change-Id: Ia4c2c52b8803cd36d7ed32be559ba446589377e7
2014-05-26 03:29:09 +02:00
Markus Mohrhard
8097fff2cc remove unnecessary debug message
Change-Id: I63e65bce671d1feab4ea93bdff906b597ce180c3
2014-05-26 03:29:09 +02:00
Markus Mohrhard
d0f2ea6aef improve screen text positioning
Change-Id: Ia1f4ae40b8dbed2324c600f7ef68a33a5b04027b
2014-05-26 03:29:09 +02:00
Markus Mohrhard
257510bffb block user input while we are in another user interaction
Change-Id: I25a846b0648d2d28585a58066a9bb1088d607c24
2014-05-26 03:29:08 +02:00
Markus Mohrhard
b8dc914cdc adapt bar size to demo
Change-Id: Id746ce00f9e91397a3edf0b39bf7dbb08ea59885
2014-05-26 03:29:08 +02:00
Markus Mohrhard
d06ce014ed add initial work on zoom into the bar movement
Change-Id: Idc8c1f27dbeafdf34706f09c890f202849c2ce33
2014-05-26 03:29:08 +02:00
Markus Mohrhard
22e1895acb remove more unused methods
Change-Id: If50cb8b21aa7b7196027a411f207eff9aee3676a
2014-05-26 03:29:07 +02:00
Markus Mohrhard
64b5ba4bfa remove unused method and shader
Change-Id: Ic4aafe0aa596f97ea4220e6fc063a61fa13b877d
2014-05-26 03:29:07 +02:00
Markus Mohrhard
3fbaec0501 let us not implement this large constructor in the header file
Change-Id: I271882d8cba0201b6aa63308e502509b3c2ac170
2014-05-26 03:29:07 +02:00
Markus Mohrhard
36943e981b initial work on screen text
Screen text is positioned in screen coordinates and therefore in 2D.
This means it will not move with the camera.

Change-Id: I3cf2e8859871ebc8034396b4c2d6f1ff9fe5d9f6
2014-05-26 03:29:07 +02:00
Stephan Bergmann
f9d9aceb1c -Werror,-Wunused-private-field
Change-Id: If9f6ce2316498597978e3d401451a9fef01427ec
2014-05-25 22:08:43 +02:00
Markus Mohrhard
fe45492694 remove unused variables
Change-Id: I020be0cecd3becc24edc1267b4bce714db3bb627
2014-05-25 21:58:08 +02:00
Markus Mohrhard
45c25954db remove all the unused functions
Change-Id: Idb78a97793615ff0ccb5377d87442deaaa09161d
2014-05-25 21:58:08 +02:00
Markus Mohrhard
14a443c107 avoid magic numbers
Change-Id: Ib7c3bd23e119ebee91f3f76b073faf10daa87b3e
2014-05-25 21:58:08 +02:00
Markus Mohrhard
d051a1a677 implement movement from one corner to the next
Change-Id: I6c782f7630c9f77e3e3f28a79e26391e8c97c706
2014-05-25 21:58:08 +02:00
Markus Mohrhard
c8d07416e3 reduce the number of traingles per bar
Change-Id: If24391481c916b689e8c8e90d6430bf7ca56a5e3
2014-05-25 21:58:07 +02:00
Stephan Bergmann
c31f50f638 loplugin:passstuffbyref
Change-Id: Ie6d413862a402a779032241c7456b14653a7489f
2014-05-25 21:47:12 +02:00
weigao
74042bc601 add delete shape function
Change-Id: Ided3902a45c6bb7bf79827849aeca3caaaa40f83
2014-05-25 12:15:15 +02:00
weigao
32b3f7876b fix the bar model generate
Change-Id: I8df87b27dd93f0e11198998869b97754ded3bca1
2014-05-25 12:13:55 +02:00
Jan Holesovsky
04e3af7a04 Improve computation of the text area to make it nicer.
Change-Id: I24fb1caedc55dcc297fb013acb63b3c660fcf0a2
2014-05-25 11:43:14 +02:00
Markus Mohrhard
fa97a8b91b some work on mouse scrolling and improved mouse dragging
Change-Id: I3265e26530183b2fc4fd7f67319f3dc124353c2e
2014-05-24 23:45:01 +02:00
Caolán McNamara
f2a01771ea WaE: -Werror=unused-parameter
Change-Id: If24b57d3372f7b2310ee9d10315d647985393500
2014-05-24 18:09:29 +01:00
Michael Meeks
f2e0eafabc Stub mouse move events propagation to 3D charts.
Change-Id: If87545df4b1caeece107a20e0c00df88fb8e6fd5
2014-05-24 17:41:49 +02:00
Markus Mohrhard
9ef8f82cb9 much improved camera control for 3D chart
Change-Id: I5acc481db01e2ea66c11933ec05f222858ba36f9
2014-05-24 17:38:06 +02:00
Markus Mohrhard
20e4e65b65 add a text cache to improve rendering performance
Change-Id: I5b3fbe9476f0eafed4524f57aa7bf65dfd029c1d
2014-05-24 17:38:06 +02:00
Markus Mohrhard
4f8d97753f fix chart background color
Change-Id: I4bda3201dff1094a7fd646c620b016532a4fbc77
2014-05-24 17:38:06 +02:00
Markus Mohrhard
ead6136ba9 add text on both sides of the chart
Change-Id: I12d5f5e92bf908bc6d8fbd0e88293e1fcaa31c96
2014-05-24 17:38:06 +02:00
Markus Mohrhard
72dcc910a0 remove camera positioning from OpenGL code
Change-Id: I70a654282e8b187bc3d78041c44af17a11b4a622
2014-05-24 17:38:06 +02:00
Markus Mohrhard
904eb232d2 Revert "add reverse bars code"
This reverts commit 07ef1602dfc48301031dc92d1795a42c2b6d8769.
2014-05-24 17:38:06 +02:00
Thomas Arnhold
75648d6e97 cppcheck: redundantAssignment
Change-Id: Icf71dc6735b9b60f6fea4dc8c78877bb652fbe95
2014-05-24 15:46:43 +02:00
Markus Mohrhard
10c14f13a7 improve the bar and text positioning
Keep a bit of space to the border and move the text a bit away from the
chart area. This makes it look much better in my opinion.

Change-Id: I1eee505e8361cbc0e3ca859d74a96af880451198
2014-05-24 13:07:46 +02:00
Markus Mohrhard
e41c33b376 make sure that OpenGL charts are rendered after import
Change-Id: I3701a7593d7394abc39532a87b9aa50a3c92d457
2014-05-24 12:36:48 +02:00
weigao
fed8631d31 modify the camera position to show the whole scene
Change-Id: I0d197295046a478d59f4260f2931fbaec9a17a33
2014-05-24 10:48:44 +02:00
Markus Mohrhard
08c1c40605 the destructor alreadz clears the vector
Change-Id: I085e3463251a7d73be9724ae56bd6aa3fcf50a34
2014-05-24 10:48:44 +02:00
weigao
2d3d63a3da fix the calling of polygon API
Change-Id: I14d7e8594dae86830ca05aeb28633feac0a258cc
2014-05-24 10:48:44 +02:00
weigao
7c603d4a23 fix the polygon normal
Change-Id: I89f27b409cf04f98f90bdc61396a8c58ec91d7f7
2014-05-24 10:48:44 +02:00
weigao
f09e321001 fix polygon render
Change-Id: Id808ce630f6b3a15a31fdcfac99b332ed5f7f29f
2014-05-24 10:48:44 +02:00