Skip to content

Commit

Permalink
Backmerge: #3017 - Using setMolecule with molfile does not rescale bo…
Browse files Browse the repository at this point in the history
…nd lengths (#4112)

- added molecules scaling in setMolecule and addFragment api methods.
  • Loading branch information
rrodionov91 authored Feb 21, 2024
1 parent b6e3719 commit 3e945af
Show file tree
Hide file tree
Showing 12 changed files with 10 additions and 8 deletions.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Original file line number Diff line number Diff line change
Expand Up @@ -5,14 +5,14 @@
M V30 BEGIN CTAB
M V30 COUNTS 8 8 0 0 0
M V30 BEGIN ATOM
M V30 1 C 12.1307 -9.2075 0.0 0
M V30 2 C 12.1307 -7.6675 0.0 0
M V30 3 N 13.4653 -9.9775 0.0 0
M V30 4 C 14.7989 -9.2075 0.0 0
M V30 5 C 14.7989 -7.6675 0.0 0 CFG=1
M V30 6 O 13.4653 -6.8975 0.0 0
M V30 7 N 16.1325 -9.9775 0.0 0
M V30 8 C 16.1326 -6.8975 0.0 0
M V30 1 C 12.8325 -8.93744 0.0 0
M V30 2 C 12.8325 -7.93756 0.0 0
M V30 3 N 13.699 -9.43739 0.0 0
M V30 4 C 14.5649 -8.93744 0.0 0
M V30 5 C 14.5649 -7.93756 0.0 0 CFG=1
M V30 6 O 13.699 -7.43761 0.0 0
M V30 7 N 15.4308 -9.43739 0.0 0
M V30 8 C 15.4309 -7.43761 0.0 0
M V30 END ATOM
M V30 BEGIN BOND
M V30 1 1 1 2
Expand Down
2 changes: 2 additions & 0 deletions packages/ketcher-core/src/application/ketcher.ts
Original file line number Diff line number Diff line change
Expand Up @@ -321,6 +321,7 @@ export class Ketcher {
this,
);

struct.rescale();
this.#editor.struct(struct);
this.#editor.zoomAccordingContent(struct);
this.#editor.centerStruct();
Expand All @@ -341,6 +342,7 @@ export class Ketcher {
this,
);

struct.rescale();
this.#editor.structToAddFragment(struct);
}
}, this.eventBus);
Expand Down

0 comments on commit 3e945af

Please sign in to comment.