Ticket #10347 (closed: fixed)

Opened 6 years ago

Last modified 5 years ago

Interpreting existing gui actions

Reported by: Owen Arnold Owned by: Harry Jeffery
Priority: major Milestone: Release 3.3
Component: Reflectometry Keywords:
Cc: Blocked By: #10237
Blocking: Tester: Federico M Pouzols

Description (last modified by Owen Arnold) (diff)

Actions following #10303

All these changes should apply to the new reflectometry GUI. Do not retrospectively fix the old gui.

Change History

comment:1 Changed 6 years ago by Owen Arnold

  • Description modified (diff)
  • Blocked By 10303 added; 10103 removed

comment:2 Changed 6 years ago by Owen Arnold

  • Blocked By 10303 removed

(In #10303) All actions agreed and answered. Ticket created #10347. No code changes.

comment:3 Changed 6 years ago by Harry Jeffery

  • Status changed from new to assigned

comment:4 Changed 6 years ago by Harry Jeffery

  • Blocked By 10237 added

Option for rounding/truncating requires #10237 to be in place first.

comment:5 Changed 6 years ago by Harry Jeffery

  • Status changed from assigned to inprogress

comment:6 Changed 6 years ago by Harry Jeffery

Refs #10347 Use declarative bindings in options dialog

Instead of manually having to load/save options to/from widgets in QtReflOptionsDialog, we now load/save options using a map binding options to widgets. It may seem overkill for just one option, but when we have fifteen to twenty it'll greatly simplify our life.

It could be expanded in future to build the bindings from widget properties in the UI file, so new options need not even touch QtReflOptionsDialog's code.

Changeset: 750be02b6236777d0f2844e42825ada770acb893

comment:7 Changed 6 years ago by Harry Jeffery

Refs #10347 Add rounding options

Users may now individually specify what level of rounding is applied to the angle, qmin, qmax, and resolution columns.

Changeset: 59e9d1f09b18fbea29a837e8288305af25415e60

comment:8 Changed 6 years ago by Harry Jeffery

Refs #10347 Add option for warning when discarding changes

Changeset: 265487c8894d3d3ea356823b9b2adf4ac6bd4bc1

comment:9 Changed 6 years ago by Harry Jeffery

Refs #10347 Automatically bind options to widgets

Use the reflOptionName property on a widget to specify the option its value should control.

Changeset: b384245252303224b054806cf829998b31574cef

comment:10 Changed 6 years ago by Harry Jeffery

Refs #10347 Remove "Apply" button from options dialog

It has no advantage over the "Ok" button. The dialog forces itself to remain in the foreground, so nothing can happen between the user hitting "Apply" and closing the dialog. We may as well be tidy and remove it.

Changeset: b86b82205a8e48ce9053f064db44ef6571611e61

comment:11 Changed 6 years ago by Harry Jeffery

Refs #10347 Correct unit tests

Now that we are not rounding by default, the expected values for unit testing need to be updated.

Changeset: 4344828ad5937d7b1343f4211d6fa69741183ce8

comment:12 Changed 6 years ago by Harry Jeffery

Refs #10347 Use TS_ASSERT_DELTA

Changeset: fe12e9463c1e233c0f29ea358f28c0603f9a90ef

comment:13 Changed 6 years ago by Harry Jeffery

  • Status changed from inprogress to verify
  • Resolution set to fixed

Testing

  • Try out the updated options dialog
    • Check the rounding options work
    • Check the options are all loaded/saved correctly
  • Verify unit tests are passing

comment:14 Changed 6 years ago by Harry Jeffery

  • Component changed from Framework to Reflectometry

comment:15 Changed 6 years ago by Harry Jeffery

Merge branch 'master' into feature/10347_refl_interpret_existing_actions

Refs #10347

Conflicts:

Code/Mantid/MantidQt/CustomInterfaces/src/ReflMainViewPresenter.cpp Code/Mantid/MantidQt/CustomInterfaces/test/ReflMainViewPresenterTest.h

Changeset: f8fc6bff8960370d71934525961b890449d10234

comment:16 Changed 6 years ago by Federico M Pouzols

  • Status changed from verify to verifying
  • Tester set to Federico M Pouzols

comment:17 Changed 6 years ago by Federico M Pouzols

  • Status changed from verifying to closed

All looks fine. I verified that:

  • options persist between dialog runs and MantidPlot runs (and spin boxes' values are saved regardless of whether their checked on/off)
  • the rounding works well, (very convenient!) and multiple runs with different digit settings produce the same results
  • tests pass
  • output workspaces are named IvsQ_{run_number}
  • other errors that a lousy user (me) could make are handled gracefully
  • the code looks sound and well organized. The options map binding will keep the code tidy and potentially save a lot of hassle in the future

One minor point that could be checked later, as the refl gui grows: the rounding options (QSpinBoxes) accept values in the range [0,99] but I understand that in practice Mantid algorithms work in double precision, so 15-16 digits would be the very maximum. Also, that's what you see in the end no matter how high you set the rounding options. The spin boxes max property could be set accordingly.

Another minor point: I understand the number of options may grow a lot. Users tend to get lost after modifying too many options. At some point it may become convenient to add a 'restore default options'.

comment:18 Changed 6 years ago by Harry Jeffery

Merge branch 'master' into feature/10347_refl_interpret_existing_actions

Refs #10347

Conflicts:

Code/Mantid/MantidQt/CustomInterfaces/src/ReflMainViewPresenter.cpp Code/Mantid/MantidQt/CustomInterfaces/test/ReflMainViewPresenterTest.h

Full changeset: f8fc6bff8960370d71934525961b890449d10234

comment:19 Changed 6 years ago by Federico Montesino Pouzols

Merge remote-tracking branch 'origin/feature/10347_refl_interpret_existing_actions'

Full changeset: 923f69300554dfb498411c0aeae71201673ed18f

comment:20 Changed 5 years ago by Stuart Campbell

This ticket has been transferred to github issue 11189

Note: See TracTickets for help on using tickets.