flutter3d_editor_widgets 0.8.0
flutter3d_editor_widgets: ^0.8.0 copied to clipboard
Shared editor controls — a number field, a colour field, a section label, a range slider, an enum dropdown, a texture slot row, a texture path field, a colour swatch field and the FieldRow they assemb [...]
0.8.0 #
Moves with the stack to 0.8.0, whose flutter3d_hardware changes
PassEncoder.bindTexture to return bool and makes every backend forget its
bindings at bindPipeline. Nothing in this package changed.
Its flutter3d_* dependencies ask for ^0.8.0.
0.7.1 #
Released with the rest of the stack at 0.7.1. Nothing in this package changed. The release it resolves against builds from pub.dev again and no longer crashes Metal on the first unlit draw.
Its flutter3d_* dependencies ask for ^0.7.1.
0.7.0 #
- The first publication, and the number skips. 0.1.0, 0.2.0 and 0.3.0
below were numbers this package carried inside the workspace; none of them
reached pub.dev, so nobody outside saw the ones passed over. It goes out at
0.7.0 with the rest of the shelf so that one number names one tree and
^0.7.0on anyflutter3d_*package resolves against every other.doc/boundary-0.7.0.mdhas the list of the thirteen that begin here. flutter3d_formatsisflutter3d_core. The package the hints come from was folded intoflutter3d_core, which is the dependency now, at^0.7.0.RangeHint,ColorHint,TextureHintandEnumHintare imported frompackage:flutter3d_core/formats.dart. The invariant stands: neverflutter3d_editor_core, neverflutter3d_model_core.NumberFieldreads arithmetic and units.evaluateNumber(text, unit:)takes the four operators, brackets andpi, and aNumberUnitofplain,metresordegrees. Undermetresa suffix ofmm,cm,dm,m,km,inorftconverts to metres; underdegrees,deg,radandturnconvert to degrees;plainrefuses every suffix, and an unknown one answers null. A comma is still read as a decimal point and a result that is not finite is refused.NumberFieldtakesunit, andNumberField.parsetakes it as a named parameter, soparse('1/3')now returns a value.NumberFieldcan be nudged. Up and Down move the value bystep, 0.1 by default, Shift multiplies that by ten and Ctrl or Cmd by a tenth, and the label is a horizontal scrub handle at one step a pixel.labelWidthis a parameter, default 18.NumberField.showstops printing a small number as zero. It used three decimal places for everything, so an STL read at a scale of 0.001 displayed0. A magnitude of 0.01 and above still gets three places, one of 0.0001 and above gets six, anything smaller eight.- A dense row gets a dense field.
EditorWidgetsTheme.denseFieldsis true whenrowHeightis under 40, andfieldPadding()answers 6 pixels of vertical padding then and(rowHeight - 24) / 2otherwise. The text boxes inNumberField,ColorFieldandRangeSliderFieldtakeisDenseand theircontentPaddingfrom the two. The theme's defaults are unchanged. RangeSliderFieldputs its label above the slider in a narrow row. When the row is narrower than the label, the value box andkLabelBesideFrom, 150 pixels, the label is stacked and the slider keeps its length. The constructor is unchanged.- Sliders and
SectionLabeltake their look from outside.RangeSliderFieldandColorFieldno longer wrap themselves in aSliderThemewith a 3-pixel track and a 6-pixel thumb; they draw with the ambientsliderTheme.SectionLabel's default style is 11 points, weight 400, letter spacing 0.88 incolorScheme.outline, where it waslabelMediuminonSurfaceVariantat 0.6. An application that relied on either default sees a different picture and sets the theme or passesstyle.
0.3.0 #
TexturePathField,ColorSwatchField,HintTextBox/NumbersRowandFieldRow—ui-27's own P2, moved verbatim fromapps/flutter3d_editor's owneditor_inspector.dart.TexturePathField(withFilePickerDialogand thePathOfferstypedef it takes a listing through) is the level editor's own "path on disk" model for aTextureHint, from before an editor could list a project's own assets for a caller to hand in.ColorSwatchField(withColorPaletteDialog) is a swatch and a twelve-hue grid over aColorHint's own value — notColorField, which is a full HSV picker with a hex box built for a different caller; the level format's colour hint never asked for hue and saturation sliders.HintTextBoxandNumbersRowareFieldRow's own fallback for a value nothing has hinted: one text box, and a row of them for a vector, with the sameFocus(onKeyEvent: skipRemainingHandlers)that keeps a name being typed into one of them from being read as a tool shortcut by an ancestor.FieldRowitself is the point of the four: one row, typed by aMaterialHintwhen there is one — a slider for aRangeHint, a picker for aColorHint, a path field for aTextureHint, a dropdown for anEnumHint— and by the value's own type when there is not, assembled fromRangeSliderField/EnumField(this package's own P1) and the four widgets above.apps/flutter3d_editor's ownEditorInspectorandMaterialPanelnow import it from here rather than keeping their own copy;editor_inspector.dartre-exportsFieldRow/PathOffers/nothingToOfferso nothing that already imported them from that file has to change its own import. Its own controls draw withTheme.of(context)'s defaults rather than the level editor's hard-coded dark palette untilui-27's own E1 gives that application an explicitColorScheme— an accepted, temporary mismatch, not a regression: no test here or inapps/flutter3d_editorchecks colour.- 23 new tests in
field_row_test.dart, including one pinning the exactFocus-swallows-the-keystroke behaviour and one pinningapps/ flutter3d_editor's own colour-hint test's count of exactly fourTextFields per row.
0.2.0 #
RangeSliderField,EnumFieldandTextureSlotRow—ui-27's own P1, each merging two existing implementations rather than picking one.RangeSliderFieldreconciles the level editor's hint-driven slider (a nullablestepthat snaps and rounds a drag's own value, aneditabletext box for a value that may sit outside[min, max]) with the modeller's own lighter row (an optional internallabelcolumn, no box — a two-decimal number beside the thumb is enough).EnumFieldreconciles the editor's "show what a document has, even when the picker's own list does not offer it" with the modeller's own fallback for a value nothing has set.TextureSlotRowmerges the modeller's production row — a name or"None"besideChoose…/Clear— with a richer, previously unwired row's own optional thumbnail,w×h · weightsubtitle and format badge; the three stay out of the row entirely when a caller has none of them to hand in yet, soapps/flutter3d_modeler's own material panel renders exactly as it did before this step.flutter3d_formatsjoins this package's dependencies — the first of the three readsRangeHint, the secondEnumHintValue; the package's own invariant (neverflutter3d_editor_core, neverflutter3d_model_core) holds unchanged.
0.1.0 #
- The first three, moved verbatim.
SectionLabel,NumberFieldandColorFieldout ofapps/flutter3d_modeler, unchanged in behaviour, plusEditorWidgetsTheme(rowHeight/labelWidth/fieldRadius/thumbnailSize) so a row's own size comes from one place instead of each editor's own constant.SectionLabelgainsstyle/paddingoverrides wide enough to reproduceapps/flutter3d_editor's own denser look, which is why the level editor can move onto this widget later without a second copy of it —ui-27's P0.