Skip to content

Commit

Permalink
remove distance measurement including which in dialog and store
Browse files Browse the repository at this point in the history
  • Loading branch information
loveluthien committed May 14, 2024
1 parent 9afcd3c commit 4d8b6c0
Show file tree
Hide file tree
Showing 23 changed files with 11 additions and 520 deletions.
2 changes: 0 additions & 2 deletions src/components/App/UIControllerComponent.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@ import {
CatalogQueryDialogComponent,
CodeSnippetDialogComponent,
ContourDialogComponent,
DistanceMeasuringDialog,
ExternalPageDialogComponent,
FileBrowserDialogComponent,
FileInfoDialogComponent,
Expand Down Expand Up @@ -46,7 +45,6 @@ export class UIControllerComponent extends React.Component {
<TelemetryDialogComponent />
<SplashScreenComponent />
<FittingDialogComponent />
<DistanceMeasuringDialog />
</React.Fragment>
);
}
Expand Down

This file was deleted.

This file was deleted.

1 change: 0 additions & 1 deletion src/components/Dialogs/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ export * from "./AboutDialog/AboutDialogComponent";
export * from "./CatalogQueryDialog/CatalogOnlineQueryDialogComponent";
export * from "./CodeSnippetDialog/CodeSnippetDialogComponent";
export * from "./ContourDialog/ContourDialogComponent";
export * from "./DistanceMeasuringDialog/DistanceMeasuringDialog";
export * from "./DraggableDialog/DraggableDialogComponent";
export * from "./ExternalPageDialog/ExternalPageDialogComponent";
export * from "./FileBrowser/FileBrowserDialogComponent";
Expand Down

This file was deleted.

10 changes: 0 additions & 10 deletions src/components/HelpDrawer/HelpContent/ImageViewHelpContent.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,6 @@ import imageTools from "static/help/imageTools_annotated.png";
import imageTools_d from "static/help/imageTools_annotated_d.png";
import catalogSelectionButton from "static/help/imageTools_catalogSelectionButton.png";
import catalogSelectionButton_d from "static/help/imageTools_catalogSelectionButton_d.png";
import distanceMeasureButton from "static/help/imageTools_distanceMeasureButton.png";
import distanceMeasureButton_d from "static/help/imageTools_distanceMeasureButton_d.png";
import exportPNGButton from "static/help/imageTools_exportButton.png";
import exportPNGButton_d from "static/help/imageTools_exportButton_d.png";
import WCSMatchButton from "static/help/imageTools_matchButton.png";
Expand Down Expand Up @@ -168,14 +166,6 @@ export const IMAGE_VIEW_HELP_CONTENT = (
<p>
<ImageComponent light={exportPNGButton} dark={exportPNGButton_d} width="80%" />
</p>
<h3>Distance measure</h3>
<p>
This tool allows you to measure a geodesic distance between two locations on an image with mouse clicks. The geodesic line between the two clicks as well as the iso-latitude and iso-longitude lines are visualized. A shortcut
button, which brings up the Distance Measurement Dialog, is available in the dialog bar. In the dialog, you can manually provide two coordinates for the calculation and configure the styling.
</p>
<p>
<ImageComponent light={distanceMeasureButton} dark={distanceMeasureButton_d} width="80%" />
</p>
<h3>Interactive colorbar</h3>
<p>
When you hover over the colorbar, a cutoff value is applied to the raster image temporarily. Pixel values below the cutoff are rendered in grayscale. You may disable this feature in the <b>Colorbar</b> tab of the Image Viewer
Expand Down
1 change: 0 additions & 1 deletion src/components/HelpDrawer/HelpContent/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@ export * from "./CatalogSettingsOrientationHelpContent";
export * from "./CatalogSettingsSizeHelpContent";
export * from "./ContourHelpContent";
export * from "./CursorInfoHelpContent";
export * from "./DistanceMeasurementHelpContent";
export * from "./FileBrowserHelpContent";
export * from "./FileInfoHelpContent";
export * from "./HistogramHelpContent";
Expand Down
2 changes: 0 additions & 2 deletions src/components/HelpDrawer/HelpDrawerComponent.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@ import {
CATALOG_SETTINGS_SIZE_HELP_CONTENT,
CONTOUR_HELP_CONTENT,
CURSOR_INFO_HELP_CONTENT,
DISTANCE_MEASUREMENT_HELP_CONTENT,
FILE_BROWSER_HELP_CONTENT,
FILE_INFO_HELP_CONTENT,
HISTOGRAM_HELP_CONTENT,
Expand Down Expand Up @@ -61,7 +60,6 @@ import {
const HELP_CONTENT_MAP = new Map<HelpType, JSX.Element>([
// Dialog
[HelpType.CONTOUR, CONTOUR_HELP_CONTENT],
[HelpType.DISTANCE_MEASUREMENT, DISTANCE_MEASUREMENT_HELP_CONTENT],
[HelpType.FILE_BROWSER, FILE_BROWSER_HELP_CONTENT],
[HelpType.FILE_INFO, FILE_INFO_HELP_CONTENT],
[HelpType.IMAGE_FITTING, IMAGE_FITTING_HELP_CONTENT],
Expand Down
3 changes: 1 addition & 2 deletions src/components/ImageView/ImageViewComponent.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,7 @@ import "./ImageViewComponent.scss";
export enum ImageViewLayer {
RegionCreating = "regionCreating",
Catalog = "catalog",
RegionMoving = "regionMoving",
DistanceMeasuring = "distanceMeasuring"
RegionMoving = "regionMoving"
}

export function getImageViewCanvas(padding: Padding, colorbarPosition: string, backgroundColor: string = "rgba(255, 255, 255, 0)") {
Expand Down
17 changes: 1 addition & 16 deletions src/components/ImageView/Overlay/OverlayComponent.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -109,13 +109,7 @@ export class OverlayComponent extends React.Component<OverlayComponentProps> {
settings.padding.right * pixelRatio,
settings.padding.top * pixelRatio,
settings.padding.bottom * pixelRatio,
styleString,
frame.distanceMeasuring?.showCurve,
frame.isPVImage,
frame.distanceMeasuring?.transformedStart?.x,
frame.distanceMeasuring?.transformedStart?.y,
frame.distanceMeasuring?.transformedFinish?.x,
frame.distanceMeasuring?.transformedFinish?.y
styleString
);
};

Expand Down Expand Up @@ -186,15 +180,6 @@ export class OverlayComponent extends React.Component<OverlayComponentProps> {
const numbersColor = this.props.overlaySettings.numbers.color;
const labelsColor = this.props.overlaySettings.labels.color;
const darktheme = AppStore.Instance.darkTheme;
const distanceMeasuring = frame.distanceMeasuring;
const distanceMeasuringShowCurve = frame.distanceMeasuring?.showCurve;
const distanceMeasuringStart = frame.distanceMeasuring?.start;
const distanceMeasuringFinish = frame.distanceMeasuring?.finish;
const distanceMeasuringTransformedStart = frame.distanceMeasuring?.transformedStart;
const distanceMeasuringTransformedFinish = frame.distanceMeasuring?.transformedFinish;
const distanceMeasuringColor = frame.distanceMeasuring?.color;
const distanceMeasuringFontSize = frame.distanceMeasuring?.fontSize;
const distanceMeasuringLineWidth = frame.distanceMeasuring?.lineWidth;
const title = this.props.overlaySettings.title.customText ? frame.titleCustomText : frame.filename;
const ratio = AppStore.Instance.imageRatio;
const titleStyleString = this.props.overlaySettings.title.styleString;
Expand Down

0 comments on commit 4d8b6c0

Please sign in to comment.